The UNIX and Linux Forums  

Go Back   The UNIX and Linux Forums > Top Forums > High Level Programming
Google UNIX.COM



View Single Post in UNIX Forums - Click on the Thread or Permalink to View Entire Thread -->
  #6 (permalink)  
Old 06-30-2007
porter porter is offline
Registered User
 

Join Date: Jan 2007
Posts: 2,965
Quote:
Originally Posted by psrujan View Post
#3 0x08048b26 in main (argc=2, argv=0xbfb64324) at groute.cpp:140
140 n=atoi(argv[2]); // mxn layout

Its giving error for n but not m.. i dont know why
Are you setting up the program arguments before you run it it?

If you give atoi a rubbish pointer it will trap.

Print out argc and argv before this traps.
Reply With Quote