× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.





Hall, Philip wrote:



-----Original Message-----
Subject: [C400-L] Program ends, no messages, logs, etc

I am running a program that does a real quick and easy call to system().
I get no output that the program ends, except from a printf I do right
before the call to system. Im expecting to get some



When a program dies abnormally on the iSeries (for ILE/C) you don't get a core dump as such, what you get is either a nice CPF/MCH error message in the job log or on the status line.


Did not get either. None of my messages say "abnormally:"
It's wierd because I have the same system call in a stand alone program and it works fine.
But in this application that does the call, the parent program ( ie, that invokes the system call ) terminates.
The parent program invokes the system call in a thread, but I dont' think that would have made a difference,
nor should it kill the parent when the thread does a pthread_exit();


Have you put a printf() after the call to system() to see if you get that outputted too?

Yes and that doesn't happen. I do this:

print("Going to do the system call");
status = system(string);

printf("Going to check status" );
if ( status < 0 ) {

}


--phil




_______________________________________________
This is the C programming iSeries / AS400 (C400-L) mailing list
To post a message email: C400-L@xxxxxxxxxxxx
To subscribe, unsubscribe, or change list options,
visit: http://lists.midrange.com/mailman/listinfo/c400-l
or email: C400-L-request@xxxxxxxxxxxx
Before posting, please take a moment to review the archives
at http://archive.midrange.com/c400-l.





As an Amazon Associate we earn from qualifying purchases.

This thread ...

Follow-Ups:
Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.