rpms/uudeview/devel uudeview-debian-patches.patch, 1.1, 1.2 uudeview.spec, 1.19, 1.20 uudeview-tempname.patch, 1.1, NONE uulib-0.5.19-uuinfofile-long-headers.patch, 1.1, NONE

Adrian Reber (adrian) fedora-extras-commits at redhat.com
Wed Jun 11 08:28:43 UTC 2008


Author: adrian

Update of /cvs/extras/rpms/uudeview/devel
In directory cvs-int.fedora.redhat.com:/tmp/cvs-serv3553

Modified Files:
	uudeview-debian-patches.patch uudeview.spec 
Removed Files:
	uudeview-tempname.patch 
	uulib-0.5.19-uuinfofile-long-headers.patch 
Log Message:
* Wed Jun 11 2008 Adrian Reber <adrian at lisas.de> - 0.5.20-17
- updated to newest debian patch
- removed the other patches which are part of the debian patchset
- fixes "uudeview fails to decode any files" (#447664)


uudeview-debian-patches.patch:

Index: uudeview-debian-patches.patch
===================================================================
RCS file: /cvs/extras/rpms/uudeview/devel/uudeview-debian-patches.patch,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- uudeview-debian-patches.patch	3 Jan 2008 21:08:09 -0000	1.1
+++ uudeview-debian-patches.patch	11 Jun 2008 08:27:36 -0000	1.2
@@ -1,77 +1,3 @@
---- uudeview-0.5.20.orig/man/uudeview.1
-+++ uudeview-0.5.20/man/uudeview.1
-@@ -164,6 +164,16 @@
- verbosity. Normally, the program prints some status messages
- while reading the input files, which can be very helpful if something
- should go wrong. Use if these messages disturb you.
-+Disables progress bars. See
-+.B -n
-+option.
-+.TP
-+.B -v
-+(disables Verbosity) Disables verbose messages, i.e. notes are not
-+displayed, but does not remove warnings and errors. Is not as quiet as
-+the
-+.B -q
-+(Quiet) option.
- .TP
- .B -n
- No progress bars. Normally, UUDeview prints ASCII bars crawling up
---- uudeview-0.5.20.orig/tcl/xdeview
-+++ uudeview-0.5.20/tcl/xdeview
-@@ -59,8 +59,8 @@
- # MIME configuration
- #
- 
--ifndef MIMEGlobalTypes	""
--ifndef MIMEGlobalCap	""
-+ifndef MIMEGlobalTypes	"/etc/mime.types"
-+ifndef MIMEGlobalCap	"/etc/mailcap"
- if { ! [ catch { set env(HOME) } ] } {
-     ifndef MIMELocalTypes	$env(HOME)/.mime.types
-     ifndef MIMELocalCap		$env(HOME)/.mailcap
---- uudeview-0.5.20.orig/unix/uudeview.c
-+++ uudeview-0.5.20/unix/uudeview.c
-@@ -454,7 +454,7 @@
-     return 0;
-   }
- 
--  if ((target = fopen (stdfile, "wb")) == NULL) {
-+  if ((target = fopen (stdfile, "wbx")) == NULL) {
-     fprintf (stderr, "proc_stdin: cannot open temp file %s for writing: %s\n",
- 	     stdfile, strerror (errno));
-     _FP_free (stdfile);
-@@ -657,9 +657,6 @@
-     else switch (*(argv[number] + 1)) {
-     case '\0':
-       interact = 0;
--      if (overwrite == 0) {
--	overwrite = 1;
--      }
-       proc_stdin ();
-       break;
-     case 'a':
-@@ -699,10 +696,7 @@
- 	fprintf (stderr, "WARNING: cannot interact when reading from stdin\n");
-       }
-       else {
--	interact  = (*argv[number] == '+') ? 1 : 0;
--	if (overwrite == 0 && *argv[number] == '-') {
--	  overwrite = 1;
--	}
-+	interact = (*argv[number] == '+') ? 1 : 0;
-       }
-       break;
-     case 'm':
-@@ -773,6 +767,8 @@
-       break;
-     }
-   }
-+  if (overwrite == 0 && interact == 0 && autoren == 0)
-+    overwrite = 1;
- 
-   return 1;
- }
 --- uudeview-0.5.20.orig/uulib/uulib.c
 +++ uudeview-0.5.20/uulib/uulib.c
 @@ -872,7 +872,10 @@
@@ -108,9 +34,58 @@
    _FP_free (thefile->binfile);
    thefile->binfile = NULL;
    thefile->state  &= ~UUFILE_TMPFILE;
+@@ -1103,9 +1114,9 @@
+ 
+   while (!feof (inpfile) && 
+ 	 (uu_fast_scanning || ftell(inpfile) < maxpos)) {
+-    if (_FP_fgets (uugen_inbuffer, 511, inpfile) == NULL)
++    if (_FP_fgets (uugen_inbuffer, 1023, inpfile) == NULL)
+       break;
+-    uugen_inbuffer[511] = '\0';
++    uugen_inbuffer[1023] = '\0';
+ 
+     if (ferror (inpfile))
+       break;
+--- uudeview-0.5.20.orig/uulib/uuscan.c
++++ uudeview-0.5.20/uulib/uuscan.c
+@@ -387,10 +387,10 @@
+ 	   *attribute != '(' && *attribute != ')' &&
+ 	   *attribute != '<' && *attribute != '>' &&
+ 	   *attribute != '@' && *attribute != ',' &&
+-	   /* *attribute != ';' && */ *attribute != ':' &&
+-	   *attribute != '\\' &&*attribute != '"' &&
+-	   *attribute != '/' && /* *attribute != '[' &&
+-	   *attribute != ']' && */ *attribute != '?' &&
++	   *attribute != ';' && *attribute != ':' &&
++	   *attribute != '\\' && *attribute != '"' &&
++	   *attribute != '/' && *attribute != '[' &&
++	   *attribute != ']' && *attribute != '?' &&
+ 	   *attribute != '=' && length < 255) {
+       *ptr++ = *attribute++;
+       length++;
+--- uudeview-0.5.20.orig/uulib/uustring.h
++++ uudeview-0.5.20/uulib/uustring.h
+@@ -36,3 +36,4 @@
+ #define S_MIME_B_NOT_FOUND    35
+ #define S_MIME_MULTI_DEPTH    36
+ #define S_MIME_PART_MULTI     37
++#define S_OPEN_FILE           38
 --- uudeview-0.5.20.orig/uulib/uunconc.c
 +++ uudeview-0.5.20/uulib/uunconc.c
-@@ -1325,9 +1325,9 @@
+@@ -1311,6 +1311,12 @@
+   char *mode, *ntmp;
+   uufile *iter;
+   size_t bytes;
++#define HAVE_MKSTEMP
++#ifdef HAVE_MKSTEMP
++  int tmpfd;
++  const char *tmpprefix = "uuXXXXXX";
++  char *tmpdir = NULL;
++#endif /* HAVE_MKSTEMP */
+ 
+   if (data == NULL || data->thisfile == NULL)
+     return UURET_ILLVAL;
+@@ -1325,17 +1331,39 @@
      return UURET_NODATA;
  
    if (data->uudet == PT_ENCODED)
@@ -120,19 +95,74 @@
 -    mode = "wb";	/* otherwise in binary          */
 +    mode = "wbx";	/* otherwise in binary          */
  
++#ifdef HAVE_MKSTEMP
++  if ((getuid()==geteuid()) && (getgid()==getegid())) {
++	  tmpdir=getenv("TMPDIR");
++  }
++
++  if (!tmpdir) {
++	  tmpdir = "/tmp";
++  }
++  data->binfile = malloc(strlen(tmpdir)+strlen(tmpprefix)+2);
++
++  if (!data->binfile) {
++#else
    if ((data->binfile = tempnam (NULL, "uu")) == NULL) {
++#endif /* HAVE_MKSTEMP */
      UUMessage (uunconc_id, __LINE__, UUMSG_ERROR,
-@@ -1437,6 +1437,9 @@
+ 	       uustring (S_NO_TEMP_NAME));
+     return UURET_NOMEM;
+   }
+ 
++#ifdef HAVE_MKSTEMP
++  strcpy(data->binfile, tmpdir);
++  strcat(data->binfile, "/");
++  strcat(data->binfile, tmpprefix);
++
++  if ((tmpfd = mkstemp(data->binfile)) == -1 || 
++	  (dataout = fdopen(tmpfd, mode)) == NULL) {
++#else
+   if ((dataout = fopen (data->binfile, mode)) == NULL) {
++#endif /* HAVE_MKSTEMP */
+     /*
+      * we couldn't create a temporary file. Usually this means that TMP
+      * and TEMP aren't set
+@@ -1343,6 +1371,12 @@
+     UUMessage (uunconc_id, __LINE__, UUMSG_ERROR,
+ 	       uustring (S_WR_ERR_TARGET),
+ 	       data->binfile, strerror (uu_errno = errno));
++#ifdef HAVE_MKSTEMP
++	if (tmpfd != -1) {
++		unlink(data->binfile);
++		close(tmpfd);
++    }
++#endif /* HAVE_MKSTEMP */
+     _FP_free (data->binfile);
+     data->binfile = NULL;
+     uu_errno = errno;
+@@ -1437,6 +1471,9 @@
  	res = UURET_IOERR;
  	break;
        }
 +      UUMessage (uunconc_id, __LINE__, UUMSG_MESSAGE,
-+		 uustring (S_OPEN_FILE),
-+		 iter->data->sfname);
++		uustring (S_OPEN_FILE),
++		iter->data->sfname);
        _FP_strncpy (uugen_fnbuffer, iter->data->sfname, 1024);
      }
  
-@@ -1502,7 +1505,7 @@
+@@ -1496,13 +1533,19 @@
+    */
+ 
+   if (data->uudet == BH_ENCODED && data->binfile) {
++#ifdef HAVE_MKSTEMP
++	  ntmp = malloc(strlen(tmpdir)+strlen(tmpprefix)+2);
++	  
++	  if (ntmp == NULL) {
++#else
+     if ((ntmp = tempnam (NULL, "uu")) == NULL) {
++#endif /* HAVE_MKSTEMP */
+       UUMessage (uunconc_id, __LINE__, UUMSG_ERROR,
+ 		 uustring (S_NO_TEMP_NAME));
        progress.action = 0;
        return UURET_NOMEM;
      }
@@ -141,23 +171,34 @@
        UUMessage (uunconc_id, __LINE__, UUMSG_ERROR,
  		 uustring (S_NOT_OPEN_FILE),
  		 data->binfile, strerror (uu_errno = errno));
---- uudeview-0.5.20.orig/uulib/uuscan.c
-+++ uudeview-0.5.20/uulib/uuscan.c
-@@ -387,10 +387,10 @@
- 	   *attribute != '(' && *attribute != ')' &&
- 	   *attribute != '<' && *attribute != '>' &&
- 	   *attribute != '@' && *attribute != ',' &&
--	   /* *attribute != ';' && */ *attribute != ':' &&
--	   *attribute != '\\' &&*attribute != '"' &&
--	   *attribute != '/' && /* *attribute != '[' &&
--	   *attribute != ']' && */ *attribute != '?' &&
-+	   *attribute != ';' && *attribute != ':' &&
-+	   *attribute != '\\' && *attribute != '"' &&
-+	   *attribute != '/' && *attribute != '[' &&
-+	   *attribute != ']' && *attribute != '?' &&
- 	   *attribute != '=' && length < 255) {
-       *ptr++ = *attribute++;
-       length++;
+@@ -1510,12 +1553,27 @@
+       free (ntmp);
+       return UURET_IOERR;
+     }
++
++#ifdef HAVE_MKSTEMP
++    strcpy(ntmp, tmpdir);
++    strcat(ntmp, "/");
++    strcat(ntmp, tmpprefix); 
++    if ((tmpfd = mkstemp(ntmp)) == -1 ||
++		(dataout = fdopen(tmpfd, "wb")) == NULL) {
++#else
+     if ((dataout = fopen (ntmp, "wb")) == NULL) {
++#endif /* HAVE_MKSTEMP */
+       UUMessage (uunconc_id, __LINE__, UUMSG_ERROR,
+ 		 uustring (S_NOT_OPEN_TARGET),
+ 		 ntmp, strerror (uu_errno = errno));
+       progress.action = 0;
+       fclose (datain);
++#ifdef HAVE_MKSTEMP
++	  if (tmpfd != -1) {
++		  unlink(ntmp);
++		  close(tmpfd);
++	  }
++#endif /* HAVE_MKSTEMP */
+       free   (ntmp);
+       return UURET_IOERR;
+     }
 --- uudeview-0.5.20.orig/uulib/uustring.c
 +++ uudeview-0.5.20/uulib/uustring.c
 @@ -107,6 +107,7 @@
@@ -168,13 +209,119 @@
  
    { 0, "" }
  };
---- uudeview-0.5.20.orig/uulib/uustring.h
-+++ uudeview-0.5.20/uulib/uustring.h
-@@ -36,3 +36,4 @@
- #define S_MIME_B_NOT_FOUND    35
- #define S_MIME_MULTI_DEPTH    36
- #define S_MIME_PART_MULTI     37
-+#define S_OPEN_FILE           38
+--- uudeview-0.5.20.orig/unix/uudeview.c
++++ uudeview-0.5.20/unix/uudeview.c
+@@ -443,18 +443,46 @@
+   FILE *target;
+   size_t bytes;
+   int res;
++#define HAVE_MKSTEMP
++#ifdef HAVE_MKSTEMP
++  int tmpfd;
++  const char *tmpprefix = "uuXXXXXX";
++  char *tmpdir = NULL;
++#endif /* HAVE_MKSTEMP */
+ 
+   if (stdinput) {
+     fprintf (stderr, "proc_stdin: cannot process stdin twice\n");
+     return 0;
+   }
+ 
++#ifdef HAVE_MKSTEMP
++  if ((getuid()==geteuid()) && (getgid()==getegid())) {
++	tmpdir=getenv("TMPDIR");
++  }
++
++  if (!tmpdir) {
++	tmpdir = "/tmp";
++  }
++  stdfile = malloc(strlen(tmpdir)+strlen(tmpprefix)+2);
++
++  if (!stdfile) {
++#else
+   if ((stdfile = tempnam (NULL, "uu")) == NULL) {
++#endif
+     fprintf (stderr, "proc_stdin: cannot get temporary file\n");
+     return 0;
+   }
+ 
+-  if ((target = fopen (stdfile, "wb")) == NULL) {
++#ifdef HAVE_MKSTEMP
++  strcpy(stdfile, tmpdir);
++  strcat(stdfile, "/");
++  strcat(stdfile, tmpprefix);
++
++  if ((tmpfd = mkstemp(stdfile)) == -1 ||
++	  (target = fdopen(tmpfd, "wbx")) == NULL) {
++#else
++  if ((target = fopen (stdfile, "wbx")) == NULL) {
++#endif
+     fprintf (stderr, "proc_stdin: cannot open temp file %s for writing: %s\n",
+ 	     stdfile, strerror (errno));
+     _FP_free (stdfile);
+@@ -657,9 +685,6 @@
+     else switch (*(argv[number] + 1)) {
+     case '\0':
+       interact = 0;
+-      if (overwrite == 0) {
+-	overwrite = 1;
+-      }
+       proc_stdin ();
+       break;
+     case 'a':
+@@ -699,10 +724,7 @@
+ 	fprintf (stderr, "WARNING: cannot interact when reading from stdin\n");
+       }
+       else {
+-	interact  = (*argv[number] == '+') ? 1 : 0;
+-	if (overwrite == 0 && *argv[number] == '-') {
+-	  overwrite = 1;
+-	}
++	interact = (*argv[number] == '+') ? 1 : 0;
+       }
+       break;
+     case 'm':
+@@ -773,6 +795,8 @@
+       break;
+     }
+   }
++  if (overwrite == 0 && interact == 0 && autoren == 0)
++    overwrite = 1;
+ 
+   return 1;
+ }
+--- uudeview-0.5.20.orig/man/uudeview.1
++++ uudeview-0.5.20/man/uudeview.1
+@@ -164,6 +164,16 @@
+ verbosity. Normally, the program prints some status messages
+ while reading the input files, which can be very helpful if something
+ should go wrong. Use if these messages disturb you.
++Disables progress bars. See
++.B -n
++option.
++.TP
++.B -v
++(disables Verbosity) Disables verbose messages, i.e. notes are not
++displayed, but does not remove warnings and errors. Is not as quiet as
++the
++.B -q
++(Quiet) option.
+ .TP
+ .B -n
+ No progress bars. Normally, UUDeview prints ASCII bars crawling up
+--- uudeview-0.5.20.orig/tcl/xdeview
++++ uudeview-0.5.20/tcl/xdeview
+@@ -59,8 +59,8 @@
+ # MIME configuration
+ #
+ 
+-ifndef MIMEGlobalTypes	""
+-ifndef MIMEGlobalCap	""
++ifndef MIMEGlobalTypes	"/etc/mime.types"
++ifndef MIMEGlobalCap	"/etc/mailcap"
+ if { ! [ catch { set env(HOME) } ] } {
+     ifndef MIMELocalTypes	$env(HOME)/.mime.types
+     ifndef MIMELocalCap		$env(HOME)/.mailcap
 --- uudeview-0.5.20.orig/man/uuwish.1
 +++ uudeview-0.5.20/man/uuwish.1
 @@ -0,0 +1,45 @@


Index: uudeview.spec
===================================================================
RCS file: /cvs/extras/rpms/uudeview/devel/uudeview.spec,v
retrieving revision 1.19
retrieving revision 1.20
diff -u -r1.19 -r1.20
--- uudeview.spec	5 May 2008 08:07:01 -0000	1.19
+++ uudeview.spec	11 Jun 2008 08:27:36 -0000	1.20
@@ -1,14 +1,12 @@
 Name:           uudeview
 Version:        0.5.20
-Release:        16
+Release:        17%{?dist}
 
 License:        GPLv2+
 Group:          Applications/File
 Source:         http://www.fpx.de/fp/Software/UUDeview/download/uudeview-0.5.20.tar.gz
 Source1:        xdeview.desktop
-Patch0:         uudeview-tempname.patch
-Patch1:         http://nget.sourceforge.net/patches/uulib-0.5.19-uuinfofile-long-headers.patch
-Patch2:         uudeview-debian-patches.patch
+Patch:          uudeview-debian-patches.patch
 URL:            http://www.fpx.de/fp/Software/UUDeview/
 Summary:        Applications for uuencoding, uudecoding, ...
 BuildRoot:      %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
@@ -41,9 +39,7 @@
 
 %prep
 %setup -q
-%patch0 -p1
-%patch1 -p0
-%patch2 -p1
+%patch -p1
 %{__sed} -i -e "s,psfig,epsfig,g" doc/library.ltx
 %{__sed} -i -e "s,for ff_subdir in lib,for ff_subdir in %{_lib},g" configure
 
@@ -90,6 +86,11 @@
 %{_libdir}/*.a
 
 %changelog
+* Wed Jun 11 2008 Adrian Reber <adrian at lisas.de> - 0.5.20-17
+- updated to newest debian patch
+- removed the other patches which are part of the debian patchset
+- fixes "uudeview fails to decode any files" (#447664)
+
 * Sun Apr 27 2008 Patrice Dumas <pertusus at free.fr> - 0.5.20-16
 - rename uulib-static to uulib-devel
 - use tex(latex) provides


--- uudeview-tempname.patch DELETED ---


--- uulib-0.5.19-uuinfofile-long-headers.patch DELETED ---




More information about the fedora-extras-commits mailing list