From 936b6fe3737c760657d82c50fa6b81c3011ffa27 Mon Sep 17 00:00:00 2001 From: Frederic Culot Date: Sat, 3 Jan 2009 21:32:10 +0000 Subject: more code cleanup --- src/custom.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'src/custom.c') diff --git a/src/custom.c b/src/custom.c index 038e252..1d29894 100755 --- a/src/custom.c +++ b/src/custom.c @@ -1,4 +1,4 @@ -/* $calcurse: custom.c,v 1.34 2009/01/02 22:28:54 culot Exp $ */ +/* $calcurse: custom.c,v 1.35 2009/01/03 21:32:11 culot Exp $ */ /* * Calcurse - text-based organizer @@ -976,7 +976,7 @@ custom_general_config (conf_t *conf) char *periodic_save_str = _("Enter the delay, in minutes, between automatic saves (0 to disable) "); int ch; - char *buf = (char *) mem_malloc (BUFSIZ); + char *buf; clear (); conf_set_scrsize (&cwin); @@ -988,8 +988,11 @@ custom_general_config (conf_t *conf) cwin.total_lines = print_general_options (cwin.pad.p, conf); wins_scrollwin_display (&cwin); + buf = mem_malloc (BUFSIZ); while ((ch = wgetch (win[STA].p)) != 'q') { + buf[0] = '\0'; + switch (ch) { case KEY_RESIZE: -- cgit v1.2.3-54-g00ecf