cplusplus
.com
TUTORIALS
REFERENCE
ARTICLES
FORUM
user name:
password:
Forgot your password?
please wait
try again
cancel
forgot your password?
sign up
log in
[Legacy version]
C++
Tutorials
Reference
Articles
Forum
Forum
Beginners
Windows Programming
UNIX/Linux Programming
General C++ Programming
Lounge
Jobs
Forum
General C++ Programming
C printf() issue
C printf() issue
Apr 25, 2013 at 5:44am
Apr 25, 2013 at 5:44am UTC
aaronfjerstad
(21)
The following code crashes the process. Does anyone know why?
1
2
3
4
5
6
#include <stdio.h>
int
main(
int
argc,
char
* argv) { printf(
"%s"
, argv[0]); }
Edit & run on cpp.sh
Apr 25, 2013 at 5:50am
Apr 25, 2013 at 5:50am UTC
cire
(8284)
The type of argv is wrong, for starters.
Apr 25, 2013 at 5:54am
Apr 25, 2013 at 5:54am UTC
aaronfjerstad
(21)
Thanks. Stupid mistake... :) Some rest is in order.
Topic archived. No new replies allowed.