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: [RFA 15/22] Use std::string in macho_symfile_read_all_oso


>>>>> "Pedro" == Pedro Alves <palves@redhat.com> writes:

>> +              if (strncmp (oso2->name, archive_name.c_str (), pfx_len) != 0)

Pedro> Since archive_name is now a std::string, we can use ==/!= for string
Pedro> comparison:
Pedro>               if (archive_name != oso2->name)

It isn't entirely clear to me that this is valid, given that the current
comparison is using strncmp.

Tom


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