This commit is contained in:
parent
29ff4de9d9
commit
5047a8d754
33
libdaemon-0.13-bnc469342.diff
Normal file
33
libdaemon-0.13-bnc469342.diff
Normal file
@ -0,0 +1,33 @@
|
|||||||
|
|
||||||
|
Index: b/libdaemon/dfork.c
|
||||||
|
===================================================================
|
||||||
|
--- a/libdaemon/dfork.c
|
||||||
|
+++ b/libdaemon/dfork.c
|
||||||
|
@@ -529,10 +529,13 @@ int daemon_close_allv(const int except_f
|
||||||
|
closedir(d);
|
||||||
|
errno = saved_errno;
|
||||||
|
|
||||||
|
return -1;
|
||||||
|
}
|
||||||
|
+
|
||||||
|
+ if (fd == _daemon_retval_pipe[0])
|
||||||
|
+ _daemon_retval_pipe[0] = -1; /* mark as closed */
|
||||||
|
}
|
||||||
|
|
||||||
|
closedir(d);
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
@@ -561,10 +564,13 @@ int daemon_close_allv(const int except_f
|
||||||
|
if (found)
|
||||||
|
continue;
|
||||||
|
|
||||||
|
if (close(fd) < 0 && errno != EBADF)
|
||||||
|
return -1;
|
||||||
|
+
|
||||||
|
+ if (fd == _daemon_retval_pipe[0])
|
||||||
|
+ _daemon_retval_pipe[0] = -1; /* mark as closed */
|
||||||
|
}
|
||||||
|
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
|
@ -1,3 +1,10 @@
|
|||||||
|
-------------------------------------------------------------------
|
||||||
|
Tue Jan 27 17:57:08 CET 2009 - seife@suse.de
|
||||||
|
|
||||||
|
- mark filedescritor as closed after closing it, preventing
|
||||||
|
application errors in e.g. avahi (bnc#469342, bnc#442210)
|
||||||
|
Thanks to Stefan Thaeter for providing the patch.
|
||||||
|
|
||||||
-------------------------------------------------------------------
|
-------------------------------------------------------------------
|
||||||
Thu Nov 27 15:55:45 CET 2008 - seife@suse.de
|
Thu Nov 27 15:55:45 CET 2008 - seife@suse.de
|
||||||
|
|
||||||
|
@ -22,12 +22,13 @@ Name: libdaemon
|
|||||||
BuildRequires: doxygen
|
BuildRequires: doxygen
|
||||||
Url: http://0pointer.de/lennart/projects/libdaemon/
|
Url: http://0pointer.de/lennart/projects/libdaemon/
|
||||||
Version: 0.13
|
Version: 0.13
|
||||||
Release: 1
|
Release: 2
|
||||||
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
|
||||||
Patch2: libdaemon-0.12-bnc449728.diff
|
Patch2: libdaemon-0.12-bnc449728.diff
|
||||||
|
Patch3: libdaemon-0.13-bnc469342.diff
|
||||||
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
||||||
|
|
||||||
%package -n libdaemon0
|
%package -n libdaemon0
|
||||||
@ -128,6 +129,7 @@ Authors:
|
|||||||
%prep
|
%prep
|
||||||
%setup -q
|
%setup -q
|
||||||
%patch2 -p1
|
%patch2 -p1
|
||||||
|
%patch3 -p1
|
||||||
|
|
||||||
%build
|
%build
|
||||||
export CFLAGS="$RPM_OPT_FLAGS"
|
export CFLAGS="$RPM_OPT_FLAGS"
|
||||||
@ -158,6 +160,10 @@ rm -rf $RPM_BUILD_ROOT
|
|||||||
%{_includedir}/libdaemon/*.h
|
%{_includedir}/libdaemon/*.h
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Tue Jan 27 2009 seife@suse.de
|
||||||
|
- mark filedescritor as closed after closing it, preventing
|
||||||
|
application errors in e.g. avahi (bnc#469342, bnc#442210)
|
||||||
|
Thanks to Stefan Thaeter for providing the patch.
|
||||||
* Thu Nov 27 2008 seife@suse.de
|
* Thu Nov 27 2008 seife@suse.de
|
||||||
- update to version 0.13:
|
- update to version 0.13:
|
||||||
- add daemon_reset_sigs() and daemon_unblock_sigs()
|
- add daemon_reset_sigs() and daemon_unblock_sigs()
|
||||||
|
Loading…
Reference in New Issue
Block a user