# HG changeset patch # User Christian Urban # Date 1412559769 -3600 # Node ID 204564b899a08ad57e33cb8171c02b6fa9ca5c3e # Parent e74a459338422426d5ced76a76c500e872c11ead progs diff -r e74a45933842 -r 204564b899a0 progs/test.c --- a/progs/test.c Mon Oct 06 02:28:53 2014 +0100 +++ b/progs/test.c Mon Oct 06 02:42:49 2014 +0100 @@ -2,40 +2,16 @@ #include #include -/* - I used as environment the virtual machine provided here - - http://www.cis.upenn.edu/~cis551/box.tar - - This is Debian/Etch with Linux 2.6.18 with gcc 4.1.2 from 2008. - - Some installation notes for this virtual machine under VMWare - are here - - http://www.cis.upenn.edu/~cis551/project1.pdf - - I run the virtial machine under MacOSX using the program - VirtualBox available for free from - - https://www.virtualbox.org - - The C-program I compiled the program with - - gcc -ggdb -fno-stack-protector -mpreferred-stack-boundary=2 - - */ - - void foo (char *bar) { - unsigned long long my_long = 101010101; // in hex: \xB5\x4A\x05\x06 + unsigned long my_long = 101010101; // in hex: \xB5\x4A\x05\x06 char buffer[28]; - printf("my_long value = %llu\n", my_long); + printf("my_long value = %lu\n", my_long); strcpy(buffer, bar); - printf("my_long value = %llu\n", my_long); + printf("my_long value = %lu\n", my_long); } int main (int argc, char **argv) diff -r e74a45933842 -r 204564b899a0 progs/test1.c --- a/progs/test1.c Mon Oct 06 02:28:53 2014 +0100 +++ b/progs/test1.c Mon Oct 06 02:42:49 2014 +0100 @@ -4,7 +4,7 @@ void foo (char *bar) { - unsigned long long my_long = 101010101; // in hex: \xB5\x4A\x05\x06 + long my_long = 101010101; // in hex: \xB5\x4A\x05\x06 } int main (int argc, char **argv)