diff --git a/slang/ChangeLog b/slang/ChangeLog index 09204a334..6fc386065 100644 --- a/slang/ChangeLog +++ b/slang/ChangeLog @@ -1,3 +1,8 @@ +2002-09-18 Andrew V. Samoilov + + * slerr.c (SLang_doerror): Use error parameter. Eliminate + err[] array. + 2002-08-21 Pavel Roskin * slsmg.c (Fake_Alt_Char_Pairs): Update from slang-1.4.5. This diff --git a/slang/slerr.c b/slang/slerr.c index 6e305555f..e2e22b46b 100644 --- a/slang/slerr.c +++ b/slang/slerr.c @@ -27,22 +27,12 @@ volatile int SLKeyBoard_Quit = 0; void SLang_doerror (char *error) { - char err [1024]; - char *str = NULL; - - *err = 0; - - str = "Slang/Midnight Commander unknown error"; - - g_snprintf(err, sizeof (err), "S-Lang Error: %s", str); - if (SLang_Error_Routine == NULL) { - fputs (err, stderr); - fputs("\r\n", stderr); + fprintf (stderr, "S-Lang Error: %s\r\n", error); } else - (*SLang_Error_Routine)(err); + (*SLang_Error_Routine)(error); }