1
1

tweaks: elide an intermediary variable that is no longer needed

Этот коммит содержится в:
Benno Schulenberg 2022-09-11 11:57:11 +02:00
родитель 7034c3cc47
Коммит 7b935e0d40

Просмотреть файл

@ -261,8 +261,6 @@ void findfile(const char *needle, bool forwards)
{
size_t looking_at = selected;
/* The location in the file list of the filename we're looking at. */
const char *thename;
/* The plain filename, without the path. */
/* Step through each filename in the list until a match is found or
* we've come back to the point where we started. */
@ -279,12 +277,9 @@ void findfile(const char *needle, bool forwards)
}
}
/* Get the bare filename, without the path. */
thename = tail(filelist[looking_at]);
/* If the needle matches, we're done. And if we're back at the file
* where we started, it is the only occurrence. */
if (mbstrcasestr(thename, needle)) {
if (mbstrcasestr(tail(filelist[looking_at]), needle)) {
if (looking_at == selected)
statusbar(_("This is the only occurrence"));
break;