c - How do I set a conditional breakpoint in gdb, when char* x points to a string whose value equals "hello"? -
can specify want gdb break @ line x when char* x points string value equals "hello"? if yes, how?
you can use strcmp:
break x:20 if strcmp(y, "hello") == 0 20 line number, x can filename , y can variable.
Comments
Post a Comment