function mallocstrcpy which is sure to be a programmatic
nightmare, changed last_search, last_replace, answer to
pointers. New function not_found_msg in search.c for displaying
- truncated strings in satusbar when the string is not found.
- We disable this feature when using PICO_MSGS (-p).
+ truncated strings in satusbar when the string is not found
+ (-pedantic fixes by Rocco Corsi). We disable this feature when
+ using PICO_MSGS (-p).
- New spelling code by Rocco Corsi. New functions
do_int_speller, do_alt_speller, changes to do_spell in nano.c,
New functions search_init_globals and do_replace_loop, changes
msgid ""
msgstr ""
"Project-Id-Version: PACKAGE VERSION\n"
-"POT-Creation-Date: 2000-11-14 20:24-0500\n"
+"POT-Creation-Date: 2000-11-14 20:33-0500\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: LANGUAGE <LL@li.org>\n"
void not_found_msg(char *str)
{
- char foo[COLS];
-
- if (strlen(str) < COLS / 2)
+ if (strlen(str) <= COLS / 2)
statusbar(_("\"%s\" not found"), str);
else {
- strncpy(foo, str, COLS / 2);
+ char *foo = NULL;
+
+ foo = mallocstrcpy(foo, str);
foo[COLS / 2] = 0;
statusbar(_("\"%s...\" not found"), foo);
+
+ free(foo);
}
}