aboutsummaryrefslogtreecommitdiff
path: root/graphics/xsane
diff options
context:
space:
mode:
authorCy Schubert <cy@FreeBSD.org>2001-12-06 13:33:33 +0000
committerCy Schubert <cy@FreeBSD.org>2001-12-06 13:33:33 +0000
commitc192fb4c5c4cb5d544841858c2104801e34e7aaa (patch)
treeab9d8e991babe2783973d015049234ac31c3594e /graphics/xsane
parente1d55a966c3ae196b64bf94c4f80895cb62273b3 (diff)
downloadports-c192fb4c5c4cb5d544841858c2104801e34e7aaa.tar.gz
ports-c192fb4c5c4cb5d544841858c2104801e34e7aaa.zip
Notes
Diffstat (limited to 'graphics/xsane')
-rw-r--r--graphics/xsane/Makefile2
-rw-r--r--graphics/xsane/distinfo2
-rw-r--r--graphics/xsane/files/patch-src::xsane-back-gtk.c37
-rw-r--r--graphics/xsane/files/patch-src::xsane-save.c10
-rw-r--r--graphics/xsane/files/patch-src::xsane-scan.c11
5 files changed, 60 insertions, 2 deletions
diff --git a/graphics/xsane/Makefile b/graphics/xsane/Makefile
index 005be6628da3..1a3881fb2a74 100644
--- a/graphics/xsane/Makefile
+++ b/graphics/xsane/Makefile
@@ -6,7 +6,7 @@
#
PORTNAME= xsane
-PORTVERSION= 0.76
+PORTVERSION= 0.81
CATEGORIES= graphics
MASTER_SITES= http://www.xsane.org/download/ \
http://gd.tuwien.ac.at/hci/sane/xsane/ \
diff --git a/graphics/xsane/distinfo b/graphics/xsane/distinfo
index 37bc38d8709d..f5289d52deaf 100644
--- a/graphics/xsane/distinfo
+++ b/graphics/xsane/distinfo
@@ -1 +1 @@
-MD5 (xsane-0.76.tar.gz) = 316af9567762af3e8ed0cb6899ee4e80
+MD5 (xsane-0.81.tar.gz) = 1b3431b812dbd2a56414d18a170e1fe6
diff --git a/graphics/xsane/files/patch-src::xsane-back-gtk.c b/graphics/xsane/files/patch-src::xsane-back-gtk.c
new file mode 100644
index 000000000000..ea5d1e225d47
--- /dev/null
+++ b/graphics/xsane/files/patch-src::xsane-back-gtk.c
@@ -0,0 +1,37 @@
+--- src/xsane-back-gtk.c.tmpfile Wed Nov 21 18:43:20 2001
++++ src/xsane-back-gtk.c Wed Nov 21 18:57:22 2001
+@@ -319,7 +319,6 @@
+ {
+ char tmpbuf[256];
+ uid_t uid;
+- int rnd;
+
+ uid = getuid();
+ snprintf(tmpbuf, sizeof(tmpbuf), "%d-", uid);
+@@ -341,12 +340,6 @@
+ memcpy(buf + len, "XXXXXX", 6); /* create unique filename */
+ len += 6;
+ buf[len] = '\0';
+- memcpy(buf, mktemp(buf), len);
+-
+- rnd = random() & 65535; /* add random number */
+- snprintf(tmpbuf, sizeof(tmpbuf), "%05d-", rnd);
+- memcpy(buf+len, tmpbuf, strlen(tmpbuf));
+- len += 6;
+ }
+
+ if (dev_name)
+@@ -410,6 +403,13 @@
+
+ buf[len++] = '\0';
+
++ {
++ int fd = mkstemp (buf);
++ if (fd == -1)
++ return -1;
++ close (fd);
++ }
++
+ DBG(DBG_proc, "path = \"%s\"\n", buf);
+
+ return 0;
diff --git a/graphics/xsane/files/patch-src::xsane-save.c b/graphics/xsane/files/patch-src::xsane-save.c
new file mode 100644
index 000000000000..89350365d871
--- /dev/null
+++ b/graphics/xsane/files/patch-src::xsane-save.c
@@ -0,0 +1,10 @@
+--- src/xsane-save.c.tmpfile Wed Nov 21 18:47:48 2001
++++ src/xsane-save.c Wed Nov 21 18:47:56 2001
+@@ -2102,7 +2102,6 @@
+
+ xsane_read_pnm_header(infile, &image_info);
+
+- remove(output_filename);
+ umask((mode_t) preferences.image_umask); /* define image file permissions */
+ outfile = fopen(output_filename, "wb"); /* b = binary mode for win32 */
+ umask(XSANE_DEFAULT_UMASK); /* define new file permissions */
diff --git a/graphics/xsane/files/patch-src::xsane-scan.c b/graphics/xsane/files/patch-src::xsane-scan.c
new file mode 100644
index 000000000000..4f1585270eb3
--- /dev/null
+++ b/graphics/xsane/files/patch-src::xsane-scan.c
@@ -0,0 +1,11 @@
+--- src/xsane-scan.c.tmpfile Wed Nov 21 18:48:01 2001
++++ src/xsane-scan.c Wed Nov 21 18:48:08 2001
+@@ -1660,7 +1660,6 @@
+ umask((mode_t) preferences.image_umask); /* define image file permissions */
+ }
+
+- remove(xsane.dummy_filename); /* remove existing file */
+ xsane.out = fopen(xsane.dummy_filename, "wb"); /* b = binary mode for win32 */
+ umask(XSANE_DEFAULT_UMASK); /* define new file permissions */
+
+