I am having trouble with this pset and I am using gdb to step through the function. Should I worry about the following observations or should I ignore them and assume my problems are from something further down the line
I set a break point to the end of the parse function and then print out the values of the pointers the parse function is supposed to be manipulating. I get the following EXPECTED output:
(gdb) print line $1 = 0x7fffffff9b80 "GET / HTTP/1.1\r\n" (gdb) print abs_path $2 = 0x7fffffffbce0 "/" (gdb) print query $3 = 0x7fffffff9ce0 ""
I then step out of the parse function and get the following UNEXPECTED output:
(gdb) s 765 } (gdb) main (argc=2, argv=0x7fffffffdeb8) at server.c:193 193 char* p = urldecode(abs_path); (gdb) print line $4 = 0x7fffffff9b80 "GET / HTTP/1.1\r\n" (gdb) print query $5 = '\000' <repeats 8190 times> (gdb) print abs_path $6 = "/", '\000' <repeats 5527 times>...
'\000' <repeats XXXX times>... mean? Does this indicate I have done something wrong and is this causing problems in the rest of the program?