This commit is contained in:
parent
a069d38a89
commit
29ff4de9d9
@ -1,40 +0,0 @@
|
|||||||
diff -Naur libdaemon-0.12/libdaemon/dpid.c /suse/mauro/libdaemon/libdaemon/dpid.c
|
|
||||||
--- libdaemon-0.12/libdaemon/dpid.c 2007-07-10 19:58:34.000000000 +0200
|
|
||||||
+++ /suse/mauro/libdaemon/libdaemon/dpid.c 2007-09-13 22:15:16.046491000 +0200
|
|
||||||
@@ -1,4 +1,4 @@
|
|
||||||
-/* $Id: dpid.c 125 2007-06-22 15:09:47Z lennart $ */
|
|
||||||
+/* $Id: dpid.c 131 2007-09-10 16:52:17Z lennart $ */
|
|
||||||
|
|
||||||
/*
|
|
||||||
* This file is part of libdaemon.
|
|
||||||
@@ -69,6 +69,14 @@
|
|
||||||
f.l_len = 0;
|
|
||||||
|
|
||||||
if (fcntl(fd, F_SETLKW, &f) < 0) {
|
|
||||||
+
|
|
||||||
+ if (enable && errno == EBADF) {
|
|
||||||
+ f.l_type = F_RDLCK;
|
|
||||||
+
|
|
||||||
+ if (fcntl(fd, F_SETLKW, &f) >= 0)
|
|
||||||
+ return 0;
|
|
||||||
+ }
|
|
||||||
+
|
|
||||||
daemon_log(LOG_WARNING, "fcntl(F_SETLKW) failed: %s", strerror(errno));
|
|
||||||
return -1;
|
|
||||||
}
|
|
||||||
@@ -91,10 +99,12 @@
|
|
||||||
}
|
|
||||||
|
|
||||||
if ((fd = open(fn, O_RDWR, 0644)) < 0) {
|
|
||||||
- if (errno != ENOENT)
|
|
||||||
- daemon_log(LOG_WARNING, "Failed to open PID file: %s", strerror(errno));
|
|
||||||
+ if ((fd = open(fn, O_RDONLY, 0644)) < 0) {
|
|
||||||
+ if (errno != ENOENT)
|
|
||||||
+ daemon_log(LOG_WARNING, "Failed to open PID file: %s", strerror(errno));
|
|
||||||
|
|
||||||
- goto finish;
|
|
||||||
+ goto finish;
|
|
||||||
+ }
|
|
||||||
}
|
|
||||||
|
|
||||||
if ((locked = lock_file(fd, 1)) < 0)
|
|
@ -1,12 +0,0 @@
|
|||||||
--- examples/testd.c
|
|
||||||
+++ examples/testd.c
|
|
||||||
@@ -116,7 +116,8 @@
|
|
||||||
|
|
||||||
/* Prepare for select() on the signal fd */
|
|
||||||
FD_ZERO(&fds);
|
|
||||||
- FD_SET(fd = daemon_signal_fd(), &fds);
|
|
||||||
+ fd = daemon_signal_fd();
|
|
||||||
+ FD_SET(fd, &fds);
|
|
||||||
|
|
||||||
while (!quit) {
|
|
||||||
fd_set fds2 = fds;
|
|
@ -1,3 +0,0 @@
|
|||||||
version https://git-lfs.github.com/spec/v1
|
|
||||||
oid sha256:339654e6002c12a78bee88a55a048182583af70db28625e0da47539bb0d8c6b9
|
|
||||||
size 257901
|
|
3
libdaemon-0.13.tar.bz2
Normal file
3
libdaemon-0.13.tar.bz2
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
version https://git-lfs.github.com/spec/v1
|
||||||
|
oid sha256:1a0ebf11385280114b210ee056382f8f39fd11b786560116573602fa90ae1010
|
||||||
|
size 272570
|
@ -1,3 +1,11 @@
|
|||||||
|
-------------------------------------------------------------------
|
||||||
|
Thu Nov 27 15:55:45 CET 2008 - seife@suse.de
|
||||||
|
|
||||||
|
- update to version 0.13:
|
||||||
|
- add daemon_reset_sigs() and daemon_unblock_sigs()
|
||||||
|
- improve error handling
|
||||||
|
- obsoletes bnc-309132.patch, libdaemon-0.10-testd-fix-FD_SET.diff
|
||||||
|
|
||||||
-------------------------------------------------------------------
|
-------------------------------------------------------------------
|
||||||
Thu Nov 27 15:36:41 CET 2008 - seife@suse.de
|
Thu Nov 27 15:36:41 CET 2008 - seife@suse.de
|
||||||
|
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
#
|
#
|
||||||
# spec file for package libdaemon (Version 0.12)
|
# spec file for package libdaemon (Version 0.13)
|
||||||
#
|
#
|
||||||
# Copyright (c) 2008 SUSE LINUX Products GmbH, Nuernberg, Germany.
|
# Copyright (c) 2009 SUSE LINUX Products GmbH, Nuernberg, Germany.
|
||||||
#
|
#
|
||||||
# All modifications and additions to the file contributed by third parties
|
# All modifications and additions to the file contributed by third parties
|
||||||
# remain the property of their copyright owners, unless otherwise agreed
|
# remain the property of their copyright owners, unless otherwise agreed
|
||||||
@ -21,14 +21,12 @@
|
|||||||
Name: libdaemon
|
Name: libdaemon
|
||||||
BuildRequires: doxygen
|
BuildRequires: doxygen
|
||||||
Url: http://0pointer.de/lennart/projects/libdaemon/
|
Url: http://0pointer.de/lennart/projects/libdaemon/
|
||||||
Version: 0.12
|
Version: 0.13
|
||||||
Release: 30
|
Release: 1
|
||||||
Summary: Lightweight C library That Eases the Writing of UNIX Daemons
|
Summary: Lightweight C library That Eases the Writing of UNIX Daemons
|
||||||
License: LGPL v2.1 or later
|
License: LGPL v2.1 or later
|
||||||
Group: System/Libraries
|
Group: System/Libraries
|
||||||
Source: %{name}-%{version}.tar.bz2
|
Source: %{name}-%{version}.tar.bz2
|
||||||
Patch0: libdaemon-0.10-testd-fix-FD_SET.diff
|
|
||||||
Patch1: bnc-309132.patch
|
|
||||||
Patch2: libdaemon-0.12-bnc449728.diff
|
Patch2: libdaemon-0.12-bnc449728.diff
|
||||||
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
||||||
|
|
||||||
@ -129,8 +127,6 @@ Authors:
|
|||||||
|
|
||||||
%prep
|
%prep
|
||||||
%setup -q
|
%setup -q
|
||||||
%patch0 -p0
|
|
||||||
%patch1 -p1
|
|
||||||
%patch2 -p1
|
%patch2 -p1
|
||||||
|
|
||||||
%build
|
%build
|
||||||
@ -163,6 +159,11 @@ rm -rf $RPM_BUILD_ROOT
|
|||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
* Thu Nov 27 2008 seife@suse.de
|
* Thu Nov 27 2008 seife@suse.de
|
||||||
|
- update to version 0.13:
|
||||||
|
- add daemon_reset_sigs() and daemon_unblock_sigs()
|
||||||
|
- improve error handling
|
||||||
|
- obsoletes bnc-309132.patch, libdaemon-0.10-testd-fix-FD_SET.diff
|
||||||
|
* Thu Nov 27 2008 seife@suse.de
|
||||||
- fix compiler warning (bnc#449728)
|
- fix compiler warning (bnc#449728)
|
||||||
* Tue Dec 18 2007 seife@suse.de
|
* Tue Dec 18 2007 seife@suse.de
|
||||||
- reenabled static libraries to fix ifplugd build
|
- reenabled static libraries to fix ifplugd build
|
||||||
|
Loading…
Reference in New Issue
Block a user