Sisyphus repositório
Última atualização: 1 outubro 2023 | SRPMs: 18631 | Visitas: 37842410
en ru br
ALT Linux repositórios
S:3.0-alt3
D:3.00g-alt1
5.0: 2.32-alt2
4.1: 2.32-alt2.M41.1
4.0: 2.32-alt1.0
3.0: 2.3-alt2

Group :: Arquivamento/Compressão
RPM: zip

 Main   Changelog   Spec   Patches   Sources   Download   Gear   Bugs e FR  Repocop 

Patch: zip-3.0-umask-tmp.patch
Download


diff --git a/zip/zip.c b/zip/zip.c
index 439821f..7c2b653 100644
--- a/zip/zip.c
+++ b/zip/zip.c
@@ -3892,9 +3892,12 @@ char **argv;            /* command line tokens */
       }
       strcat(tempzip, "ziXXXXXX");
 
+      mode_t old_umask;	/* umask prior to temp file creation */
+      old_umask = umask(0066);
       if ((yd = mkstemp(tempzip)) == EOF) {
         ZIPERR(ZE_TEMP, tempzip);
       }
+      umask(old_umask);
       if ((y = fdopen(yd, FOPW_TMP)) == NULL) {
         ZIPERR(ZE_TEMP, tempzip);
       }
@@ -4904,9 +4907,12 @@ char **argv;            /* command line tokens */
     if ((tempzip = tempname(zipfile)) == NULL) {
       ZIPERR(ZE_MEM, "allocating temp filename");
     }
+    mode_t old_umask;	/* umask prior to temp file creation */
+    old_umask = umask(0066);
     if ((y = zfopen(tempzip, FOPW_TMP)) == NULL) {
       ZIPERR(ZE_TEMP, tempzip);
     }
+    umask(old_umask);
 #endif
   }
 
 
projeto & código: Vladimir Lettiev aka crux © 2004-2005, Andrew Avramenko aka liks © 2007-2008
mantenedor atual: Michael Shigorin
mantenedor da tradução: Fernando Martini aka fmartini © 2009