diff --git a/ChangeLog b/ChangeLog index 6956521e355a06ce71b601423358cb8f0f415add..31e50b7c93f91c503e23f2bf064f9fba907c7129 100644 --- a/ChangeLog +++ b/ChangeLog @@ -16,10 +16,15 @@ CVS code - New function print1opt does most of the dirty work, stops duplication of effort and eases translator's jobs. Also breaks all the current translations ;-) +- proto.h: + - Missing externs (Rocco). - rcfile.c: parse_rcfile() - Don't use i for both for loop and atoi(), fixes lots of potential crashes, 1st reported by Jean-Philippe Guérard. +- search.c: + search_init() + - Fix a missing free (Rocco). - utils.c: stristr() - Defined regardless of NANO_SMALL (noticed by Jordi). - po/sv.po: diff --git a/proto.h b/proto.h index e7aa3e5f4192191244b3bfddb4283595c51d5c06..527527bb06b5d8755fc4d731ab6ed08f53e5b41c 100644 --- a/proto.h +++ b/proto.h @@ -40,7 +40,7 @@ extern int search_last_line; extern int currslen; #ifndef DISABLE_JUSTIFY -char *quotestr; +extern char *quotestr; #endif extern WINDOW *edit, *topwin, *bottomwin; @@ -65,7 +65,7 @@ extern filestruct *open_files; #endif #ifdef ENABLE_COLOR -colortype *colorstrings; +extern colortype *colorstrings; #endif extern shortcut *shortcut_list; diff --git a/search.c b/search.c index 6d3064a9936884031ef0c335f9a8cad6978dbf9f..b96b214b6f222b4d8cdb539c68c068341086f37d 100644 --- a/search.c +++ b/search.c @@ -145,6 +145,9 @@ int search_init(int replacing) replacing ? _(" (to replace)") : "", buf); + /* Release buf now that we don't need it anymore */ + free(buf); + /* Cancel any search, or just return with no previous search */ if ((i == -1) || (i < 0 && !last_search[0])) { statusbar(_("Search Cancelled"));