Created
June 26, 2019 17:10
-
-
Save 0x9090/2930f53f287150459fcc45c68aaf837d to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <stdio.h> | |
int main(int argc, char * argv[]) | |
{ | |
char a[1024]; | |
strcpy(a, argv[1]); | |
printf(a); | |
printf("\n"); | |
} | |
/* ------------------------ */ | |
# ls -alh | |
total 8 | |
drwxr-xr-x 3 nops ANT\Domain Users 96B Jan 10 11:26 . | |
drwxr-xr-x 9 nops ANT\Domain Users 288B Jan 10 11:25 .. | |
-rw-r--r-- 1 nops ANT\Domain Users 132B Jan 10 11:17 printer.c | |
# gcc -o printer printer.c | |
# ./printer asdf | |
asdf | |
# ls -alh | |
total 32 | |
drwxr-xr-x 4 nops ANT\Domain Users 128B Jan 10 11:25 . | |
drwxr-xr-x 9 nops ANT\Domain Users 288B Jan 10 11:25 .. | |
-rwsr-xr-x 1 nops ANT\Domain Users 8.4K Jan 10 11:21 printer | |
-rw-r--r-- 1 nops ANT\Domain Users 132B Jan 10 11:17 printer.c |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment