openbsd-ports/graphics/sane-frontends/patches/patch-src_xscanimage_c
jasper 9e30e38a7a - fix potential 64-bit issue
- regen WANTLIB, PLIST and patch-src_xscanimage_c

'ok as in ok' ajacoutot@ (MAINTAINER)
2009-02-14 10:05:21 +00:00

13 lines
639 B
Plaintext

$OpenBSD: patch-src_xscanimage_c,v 1.2 2009/02/14 10:05:21 jasper Exp $
--- src/xscanimage.c.orig Sat Apr 16 15:12:07 2005
+++ src/xscanimage.c Sat Feb 14 10:48:06 2009
@@ -1284,7 +1284,7 @@ scan_dialog (GtkWidget * widget, gpointer call_data)
{ /* We are running in standalone mode */
/* test for pnm formats */
strncpy (testfilename, preferences.filename, sizeof (testfilename));
- testfilename[sizeof (testfilename)] = 0;
+ testfilename[sizeof (testfilename) - 1] = 0;
g_strreverse (testfilename);
if (!((!strncmp (testfilename, "mnp.", 4)) ||
(!strncmp (testfilename, "mgp.", 4)) ||