473,320 Members | 1,977 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,320 software developers and data experts.

C Unix calling system() from multithreaded process

hi,

one of my friends was saying it's not a good idea to do this.

certainly on my Solaris box man system makes a similar statement.

could anyone elaborate in practicality how risky this is?

i'm currently calling the system() function from within my 64 bit c
app..

i've had to do this because my program has to work with code for which
there are only 32bit libraries - hence my system() call to the
external 32 bit command.

is there a better way of doing this?
Nov 14 '05 #1
1 1541
On 23 Nov 2004 19:25:34 -0800, ha*********@hotmail.com (talisman)
wrote in comp.lang.c:
hi,

one of my friends was saying it's not a good idea to do this.
To do what? Some newsreaders do not display the subject line when
displaying the message bodies. Always include your topic in the body
as well.

In any case, the C language does not support threads or processes, so
there is no language issue involved here.
certainly on my Solaris box man system makes a similar statement.
If your compiler documentation suggests that you should not do this,
then you probably shouldn't. If you want to know why, contact Sun
technical support or ask in a Solaris programming group. I seem to
remember that there is one.
could anyone elaborate in practicality how risky this is?
Not anyone here, no, it is off-topic.
i'm currently calling the system() function from within my 64 bit c
app..

i've had to do this because my program has to work with code for which
there are only 32bit libraries - hence my system() call to the
external 32 bit command.
There is no such thing as "64 bit C" or "32 bit libraries" in the C
language. These are implementation details of your compiler and
platform, not anything to do with the language.
is there a better way of doing this?


Yes, consulting the sources I suggested above.

--
Jack Klein
Home: http://JK-Technology.Com
FAQs for
comp.lang.c http://www.eskimo.com/~scs/C-faq/top.html
comp.lang.c++ http://www.parashift.com/c++-faq-lite/
alt.comp.lang.learn.c-c++
http://www.contrib.andrew.cmu.edu/~a...FAQ-acllc.html
Nov 14 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

7
by: Stu | last post by:
Hi, I have a web service which returns a record set and works well integrated with an asp dot net page. However if I decided to develop a unix app will i be able to read the dataset as it is...
15
by: Alpha | last post by:
I was told that Unix API can only be called using C++, ATL and MFC. However, I was also told that C# can do that through Pinvoke to a DLL that interfaces with the Unix API. Can someone direct me...
11
by: noleander | last post by:
Ive got a time-critical application that runs on Windows XP and Unix. I've got some timing issues that Ive traced to virtual memory getting paged in and out. I think I can solve the problem if...
2
by: anand.ba | last post by:
Hi all I need to find equivalent windows libraries for the following unix ones. #include <sys/prctl.h> #include <sys/ioctl.h> #include <unistd.h>
4
by: Michael | last post by:
Hi, I'm having difficulty finding any previous discussion on this -- I keep finding people either having problems calling os.exec(lepev), or with using python's exec statement. Neither of...
6
by: asimorio | last post by:
Hi folks, Recently, I am investigatin a memory leak issue. I have written a simple C++ program and a Perl script to test on UNIX environment machine. I do a for loop to new up 20 char of size...
1
by: sush | last post by:
Position: SR. S/W ENG. Job Location: BANGALORE Experience; 4 to 7yrs Job Requirements: · Graduate/post graduate degree in Computer science, engineering or technology · 4-7 years of industry...
21
by: Tom Gur | last post by:
Hi, It's seems that csh and tcsh acts a bit different when handling special characters in quotes. i.e: if i'll supply my program with the following arguments: -winpath "c:\\temp\\" tcsh will...
0
amitpatel66
by: amitpatel66 | last post by:
There is always a requirement that in Oracle Applications, the Concurrent Program need to be execute programatically based on certain conditions/validations: Concurrent programs can be executed...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
1
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.