This is the mail archive of the gdb-patches@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [patch] GDB 7.2: new feature for "backtrace" that cuts path to file (remain filename)


>>>>> "Joel" == Joel Brobecker <brobecker@adacore.com> writes:

>> I think instead of 'strstr' as a test, you want strncmp, followed by a
>> check to make sure that either the compilation directory ends with a
>> directory separator, or the following character in the source file name
>> is one.

Joel> Seems like filename_ncmp would be better?

Yeah, whoops.

Joel> (should we write a specific routine that checks whether a given
Joel> fullpath "starts with" a given directory name?)

It wouldn't hurt.

Tom


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]