Репозитории 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 |
Группа :: Архивирование/Сжатие
Пакет: zip
Главная Изменения Спек Патчи Sources Загрузить Gear Bugs and FR Repocop
Патч: zip23-umask.patch
Скачать
Скачать
diff -ur zip-2.3/zip.c zip-2.3-lhh/zip.c
--- zip-2.3/zip.c 1999-11-16 15:08:10.000000000 -0500
+++ zip-2.3-lhh/zip.c 2003-12-22 09:32:56.000000000 -0500
@@ -849,6 +849,7 @@
/* Add, update, freshen, or delete zip entries in a zip file. See the
command help in help() above. */
{
+ mode_t old_umask; /* umask prior to temp file creation */
int a; /* attributes of zip file */
ulg c; /* start of central directory */
int d; /* true if just adding to a zip file */
@@ -1830,9 +1831,11 @@
if ((tempzip = tempname(zipfile)) == NULL) {
ZIPERR(ZE_MEM, "allocating temp filename");
}
+ old_umask = umask(0066);
if ((tempzf = y = fopen(tempzip, FOPW_TMP)) == NULL) {
ZIPERR(ZE_TEMP, tempzip);
}
+ umask(old_umask);
}
#if (!defined(VMS) && !defined(CMS_MVS))