exit-code

Instant crashing after replacing calls to clock() with MPI_Wtime()

I have an MPI program that I'm developing on a local computer, but need to run on a remote machine. I used clock() to measure time, but after discovering that it doesn't work well enough on the remote machine (due to a completely different architecture), I replaced a few calls to clock() with MPI_Wtime(), which yielded the required resul...

Getting the exit code from a process submitted with qsub on Sun Grid Engine

I would like to submit jobs via qsub on Sun Grid Engine (now: Oracle Grid Engine?). I do not wish to use the -sync yes option or qrsh, because I want my controlling program to be single-threaded and able to launch many jobs at a time. These options would block my controlling program's thread. However, I would like to receive the exit ...

Specifying the Return Error Code on Application Exit

How can the return error code be specified on application exit? If this were a VC++ application, I could use the SetLastError(ERROR_ACCESS_DENIED) -- return GetLastError() APIs. Is there a way to do this in C#? static int Main(string[] args) { Tool.Args = args; Application.EnableVisualStyles(); Application.SetCompa...

List of Windows application's exit codes.

Hi. Where can I get the list of Windows application's exit codes? Thank you in advance ...

How to return an error code with Halt(n) from an Exception block with D2007?

Update: It seems to be specific to D2007. It works in D2010 like it worked in older version. I would like to return an exit code depending on the type of Exception caught in the Eception Handler block like: program test; {$APPTYPE CONSOLE} uses SysUtils; var Exitcode: Integer; begin Writeln('Enter error code:'); Readln(Exi...

Get error code from within a batch file

I have a batch file that runs a couple executables, and I want it to exit on success, but stop if the exit code <> 0. How do I do this? ...

gcc-4.2 failed with xcode 1

I have started learning opengl es. I downloaded code from the companion website, but I cannot compile any project. When I use simulator 4.0 as base SDK, I get the message /Developer/Platform/iPhoneSimulator/Platform/Developer/user/bin/gcc-4.2 failed with exit code 1. However, whet I use device 4.0 as base SDK, I am getting the message...

Exit application only when clicking 'X' button with 'Shift' key hold?

Hi everyone, Normally clicking 'X' button at the top right corner will exit the application. I want my window form application to exit only when holding the 'Shift' click. How can I do that? ...

Compiling iphone app for device - errors

I've been trying to compile an iPhone app to test on a device, it's properly provisioned and everything, but I'm getting the following error in xcode when I'm trying to build it: error: can't exec '<com.apple.tools.product-pkg-utility>' (No such file or directory) Command <com.apple.tools.product-pkg-utility> failed with exit code 71 ...

How to exit a program with an exit code: C#

How to exit a program with an exit code in C#? In java it would be System.exit(int code); ...

Can a batch file capture the exit codes of the commands it is invoking?

Basically, let's say that I have a batch file that calls myapp1.exe and myapp1.exe exits with Exit Code 1. Can the batch file capture this information and either force the batch file to exit with that same exit code or perform some other logic? ...

dangers of _exit() - memory leak?

Sorry to repeat a question that has been posed repeatedly, but i couldn't find a specific mention of memory issues. if a process terminates with _exit(0) or _Exit(0) can its memory block be lost to the OS? Thanks, -nuun ...

How do you implement 'EXIT_CODES' in python ?

Initially i thought to do something like: #EXIT CODES class ExitCode(object): (USERHOME_INVALID, \ USERHOME_CANNOT_WRITE, \ USERHOME_CANNOT_READ, \ BASHRC_INVALID) = range(-1, -5, -1) But than I've realized that I'll have to know exactly the total number of EXIT_CODES, so that I can pass it to the range() function. Let...

Why cant' I return bigger values from main function ?

I am trying to return a bigger value like 1000 form my main function, but when I type echo $? it displays 0. If I return a smaller value like 100 it displays the correct value. My Code : int main(void) { return 1000; } Is there any limitation on the values which we can return ? Thanks. ...

"Program exited with status value:5"

I've looked around a good bit and never found a comprehensive list of exit codes for Xcode especially working with iOS. This question: http://stackoverflow.com/questions/2504512/debuging-to-simulator-crashes-with-exited-with-status-5-unless-i-have-breakpoin simply says I need to restart xcode. But the problem is still there for me. So...

Are javaws exit codes really broken?

I was working to automate same java code execution using JNLP and I was surprised to discover that jawaws did not gave me a valid return code. Original execution line was: javaws -wait http://example.com:666/missing.jnlp This did showed an ugly window with "Unable to launch application." message. As you can image I tried to make thi...

Where I can find a list of "mysqldump" exit codes ?

I know that exit code = 0 means No error. I got exit code = 2. What does it means ? Where I can see the complete list of mysqldump exit codes ? ...

Why is the return value of Perl's system not what I expect?

Let me begin by explaining what I'm trying to accomplish. Essentially there are two Perl scripts. One is what I call the Main script with an UI. The user who runs this script will see a list of other scripts he can call from the menu. This list is loaded through a custom config file. The purpose of the main script is to be able to add ot...