Send patches - preferably formatted by git format-patch - to patches at archlinux32 dot org.
summaryrefslogtreecommitdiff
path: root/lib/libalpm
diff options
context:
space:
mode:
authorDan McGee <dan@archlinux.org>2008-10-12 21:36:45 -0500
committerDan McGee <dan@archlinux.org>2008-10-12 21:36:45 -0500
commitfa02a71abd62fc8b45e92ce1652b5d98174a6dca (patch)
tree44880adf216b6a634e90e76428b265e02df33b58 /lib/libalpm
parent91a013a8791b73daf4d17b2d52c8dfaf12887cc6 (diff)
parent30851a24ff68b00898565a1144926d83c623e6bf (diff)
Merge branch 'maint'
Diffstat (limited to 'lib/libalpm')
-rw-r--r--lib/libalpm/cache.c1
-rw-r--r--lib/libalpm/conflict.c1
-rw-r--r--lib/libalpm/db.c1
-rw-r--r--lib/libalpm/package.c1
-rw-r--r--lib/libalpm/trans.c5
-rw-r--r--lib/libalpm/util.c3
6 files changed, 4 insertions, 8 deletions
diff --git a/lib/libalpm/cache.c b/lib/libalpm/cache.c
index 032cc978..10857792 100644
--- a/lib/libalpm/cache.c
+++ b/lib/libalpm/cache.c
@@ -19,7 +19,6 @@
#include "config.h"
-#include <unistd.h>
#include <stdio.h>
#include <stdlib.h>
#include <errno.h>
diff --git a/lib/libalpm/conflict.c b/lib/libalpm/conflict.c
index cae237cf..499e55a4 100644
--- a/lib/libalpm/conflict.c
+++ b/lib/libalpm/conflict.c
@@ -25,7 +25,6 @@
#include <stdlib.h>
#include <stdio.h>
-#include <unistd.h>
#include <string.h>
#include <limits.h>
#include <sys/stat.h>
diff --git a/lib/libalpm/db.c b/lib/libalpm/db.c
index 0ae0c897..9b91ce47 100644
--- a/lib/libalpm/db.c
+++ b/lib/libalpm/db.c
@@ -23,7 +23,6 @@
#include "config.h"
-#include <unistd.h>
#include <stdio.h>
#include <stdlib.h>
#include <errno.h>
diff --git a/lib/libalpm/package.c b/lib/libalpm/package.c
index 13020041..ee0ff6f5 100644
--- a/lib/libalpm/package.c
+++ b/lib/libalpm/package.c
@@ -30,7 +30,6 @@
#include <errno.h>
#include <sys/types.h>
#include <sys/stat.h>
-#include <unistd.h>
/* libarchive */
#include <archive.h>
diff --git a/lib/libalpm/trans.c b/lib/libalpm/trans.c
index d2336454..73ae822e 100644
--- a/lib/libalpm/trans.c
+++ b/lib/libalpm/trans.c
@@ -30,7 +30,6 @@
#include <sys/types.h>
#include <sys/stat.h>
#include <sys/statvfs.h>
-#include <unistd.h>
#include <errno.h>
/* libalpm */
@@ -205,7 +204,7 @@ int SYMEXPORT alpm_trans_release()
/* unlock db */
if(handle->lckfd != -1) {
- close(handle->lckfd);
+ while(close(handle->lckfd) == -1 && errno == EINTR);
handle->lckfd = -1;
}
if(_alpm_lckrm()) {
@@ -567,7 +566,7 @@ int _alpm_runscriptlet(const char *root, const char *installfn,
/* this code runs for the parent only (wait on the child) */
pid_t retpid;
int status;
- retpid = waitpid(pid, &status, 0);
+ while((retpid = waitpid(pid, &status, 0)) == -1 && errno == EINTR);
if(retpid == -1) {
_alpm_log(PM_LOG_ERROR, _("call to waitpid failed (%s)\n"),
strerror(errno));
diff --git a/lib/libalpm/util.c b/lib/libalpm/util.c
index b26c9702..da3463b0 100644
--- a/lib/libalpm/util.c
+++ b/lib/libalpm/util.c
@@ -254,7 +254,8 @@ int _alpm_lckmk()
_alpm_makepath(dir);
FREE(dir);
- fd = open(file, O_WRONLY | O_CREAT | O_EXCL, 0000);
+ while((fd = open(file, O_WRONLY | O_CREAT | O_EXCL, 0000)) == -1
+ && errno == EINTR);
return(fd > 0 ? fd : -1);
}