From 6cb52deffb02eb6501e9186d0802746fe3d6b965 Mon Sep 17 00:00:00 2001 From: Karl Heuer Date: Sat, 17 Feb 1996 02:28:26 +0000 Subject: [PATCH] (Fopen_dribble_file): Close dribble file before opening new file. --- src/keyboard.c | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) diff --git a/src/keyboard.c b/src/keyboard.c index af1fb97d1a3..209bf9dc7c9 100644 --- a/src/keyboard.c +++ b/src/keyboard.c @@ -6881,15 +6881,12 @@ If FILE is nil, close any open dribble file.") (file) Lisp_Object file; { - if (NILP (file)) + if (dribble) { - if (dribble) - { - fclose (dribble); - dribble = 0; - } + fclose (dribble); + dribble = 0; } - else + if (!NILP (file)) { file = Fexpand_file_name (file, Qnil); dribble = fopen (XSTRING (file)->data, "w"); -- 2.39.2