From 3e45e512719feccaa16edfd208273bade4f724e4 Mon Sep 17 00:00:00 2001 From: Mathias Hasselmann Date: Wed, 13 Feb 2008 21:16:09 +0100 Subject: Use '.new' instead of '.conf' as filename suffix in template mode, and append that the suffix to 'filename_new' instead of 'filename', to prevent a buffer overrun for 'argv[optind]'. --- Index: lirc-0.8.7pre2/daemons/irrecord.c =================================================================== --- lirc-0.8.7pre2.orig/daemons/irrecord.c +++ lirc-0.8.7pre2/daemons/irrecord.c @@ -514,7 +514,7 @@ int main(int argc,char **argv) exit(EXIT_FAILURE); } strcpy(filename_new, filename); - strcat(filename_new, ".conf"); + strcat(filename_new, ".new"); filename = filename_new; } else