Репозиторий Sisyphus
Последнее обновление: 1 октября 2023 | Пакетов: 18631 | Посещений: 37914494
en ru br
Репозитории ALT
S:3.0-alt3
D:3.00g-alt1
5.1: 2.32-alt2
4.1: 2.32-alt2.M41.1
4.0: 2.32-alt1.0
3.0: 2.3-alt2
www.altlinux.org/Changes

Группа :: Архивирование/Сжатие
Пакет: zip

 Главная   Изменения   Спек   Патчи   Sources   Загрузить   Gear   Bugs and FR  Repocop 

Патч: zip-3.0-umask-tmp.patch
Скачать


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
   }
 
 
дизайн и разработка: Vladimir Lettiev aka crux © 2004-2005, Andrew Avramenko aka liks © 2007-2008
текущий майнтейнер: Michael Shigorin