Program Debugging
Print this page
  • Value stored in mid also correct. Check left and right expression of the if condition.

    (gdb) print argv[1][i]

    $3 = 109 'm'

    (gdb) print argv[1][length-i]

    $4 = 0 '\0'

    (gdb)

    The left expression is 'm' and the right expression is '\0' which are not equal!
 
Prev