aboutsummaryrefslogtreecommitdiffstats
path: root/src/keyboard.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/keyboard.c')
-rw-r--r--src/keyboard.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/src/keyboard.c b/src/keyboard.c
index 2be24b4f00..82f09de4f8 100644
--- a/src/keyboard.c
+++ b/src/keyboard.c
@@ -5575,8 +5575,11 @@ If FILE is nil, close any open dribble file.")
{
if (NILP (file))
{
- fclose (dribble);
- dribble = 0;
+ if (dribble)
+ {
+ fclose (dribble);
+ dribble = 0;
+ }
}
else
{