openbsd-ports/graphics/xzgv/patches/patch-src_rcfile_c
alek 57b5969b4f Import xzgv 0.8
xzgv is a picture viewer for X, with a thumbnail-based file selector.
It uses GTK+ and Imlib. Most file formats are supported, and the
thumbnails used are compatible with xv, zgv, and the Gimp. It can also
be used with `xzgv file(s)', to effectively bypass the file selector.

From Julian Leyh <oenone@oenone.de>
2005-05-22 11:32:11 +00:00

13 lines
478 B
Plaintext

$OpenBSD: patch-src_rcfile_c,v 1.1.1.1 2005/05/22 11:32:11 alek Exp $
--- src/rcfile.c.orig Thu May 12 15:39:58 2005
+++ src/rcfile.c Thu May 12 15:40:18 2005
@@ -209,7 +209,7 @@ in_config=1;
*cfgfile=0;
if(home && strlen(home)<sizeof(cfgfile)-strlen("/.xzgvrc")-1)
- sprintf(cfgfile,"%s/.xzgvrc",home);
+ snprintf(cfgfile,sizeof(cfgfile),"%s/.xzgvrc",home);
if((in=fopen(cfgfile,"r"))!=NULL)
got_rcfile=1,config_file_name="~/.xzgvrc"; /* shortened name for that */