[packages/lighttpd] drop outdated patches
glen
glen at pld-linux.org
Sun Oct 16 18:35:22 CEST 2016
commit b429b3cce05773992b05cc6a547662a7fc2ed100
Author: Elan Ruusamäe <glen at delfi.ee>
Date: Sun Oct 16 19:34:51 2016 +0300
drop outdated patches
lighttpd-modinit-before-fork.patch | 187 -------------------------------------
lighttpd.spec | 4 +-
2 files changed, 1 insertion(+), 190 deletions(-)
---
diff --git a/lighttpd.spec b/lighttpd.spec
index ceabf5a..e2cfcf6 100644
--- a/lighttpd.spec
+++ b/lighttpd.spec
@@ -107,11 +107,9 @@ Patch2: %{name}-mod_h264_streaming.patch
Patch3: %{name}-branding.patch
Patch6: test-port-setup.patch
Patch7: env-documentroot.patch
-#Patch: %{name}-modinit-before-fork.patch
-#Patch: %{name}-errorlog-before-fork.patch
URL: http://www.lighttpd.net/
-%{?with_xattr:BuildRequires: attr-devel}
%{?with_geoip:BuildRequires: GeoIP-devel}
+%{?with_xattr:BuildRequires: attr-devel}
BuildRequires: autoconf >= 2.57
%if "%{pld_release}" != "ac"
BuildRequires: automake >= 1:1.11.2
diff --git a/lighttpd-modinit-before-fork.patch b/lighttpd-modinit-before-fork.patch
deleted file mode 100644
index 2f2c5e5..0000000
--- a/lighttpd-modinit-before-fork.patch
+++ /dev/null
@@ -1,187 +0,0 @@
---- ./src/server.c (working copy)
-+++ lighttpd-1.4.19/src/server.c 2008-09-19 17:43:33.695522751 +0300
-@@ -865,34 +865,9 @@
- return -1;
- }
-
--#ifdef HAVE_FORK
-- /* network is up, let's deamonize ourself */
-- if (srv->srvconf.dont_daemonize == 0) daemonize();
--#endif
--
- srv->gid = getgid();
- srv->uid = getuid();
-
-- /* write pid file */
-- if (pid_fd != -1) {
-- buffer_copy_long(srv->tmp_buf, getpid());
-- buffer_append_string_len(srv->tmp_buf, CONST_STR_LEN("\n"));
-- write(pid_fd, srv->tmp_buf->ptr, srv->tmp_buf->used - 1);
-- close(pid_fd);
-- pid_fd = -1;
-- }
--
-- /* Close stderr ASAP in the child process to make sure that nothing
-- * is being written to that fd which may not be valid anymore. */
-- if (-1 == log_error_open(srv)) {
-- log_error_write(srv, __FILE__, __LINE__, "s", "Opening errorlog failed. Going down.");
--
-- plugins_free(srv);
-- network_close(srv);
-- server_free(srv);
-- return -1;
-- }
--
- if (HANDLER_GO_ON != plugins_call_set_defaults(srv)) {
- log_error_write(srv, __FILE__, __LINE__, "s", "Configuration of plugins failed. Going down.");
-
-@@ -918,7 +893,86 @@
- return -1;
- }
-
-+ if (NULL == (srv->ev = fdevent_init(srv->max_fds + 1, srv->event_handler))) {
-+ log_error_write(srv, __FILE__, __LINE__,
-+ "s", "fdevent_init failed");
-+ return -1;
-+ }
-+ /*
-+ * kqueue() is called here, select resets its internals,
-+ * all server sockets get their handlers
-+ *
-+ * */
-+ if (0 != network_register_fdevents(srv)) {
-+ plugins_free(srv);
-+ network_close(srv);
-+ server_free(srv);
-+
-+ return -1;
-+ }
-+
-+ /* might fail if user is using fam (not gamin) and famd isn't running */
-+ if (NULL == (srv->stat_cache = stat_cache_init())) {
-+ log_error_write(srv, __FILE__, __LINE__, "s",
-+ "stat-cache could not be setup, dieing.");
-+ return -1;
-+ }
-+
-+#ifdef HAVE_FAM_H
-+ /* setup FAM */
-+ if (srv->srvconf.stat_cache_engine == STAT_CACHE_ENGINE_FAM) {
-+ if (0 != FAMOpen2(srv->stat_cache->fam, "lighttpd")) {
-+ log_error_write(srv, __FILE__, __LINE__, "s",
-+ "could not open a fam connection, dieing.");
-+ return -1;
-+ }
-+#ifdef HAVE_FAMNOEXISTS
-+ FAMNoExists(srv->stat_cache->fam);
-+#endif
-+
-+ srv->stat_cache->fam_fcce_ndx = -1;
-+ fdevent_register(srv->ev, FAMCONNECTION_GETFD(srv->stat_cache->fam), stat_cache_handle_fdevent, NULL);
-+ fdevent_event_add(srv->ev, &(srv->stat_cache->fam_fcce_ndx), FAMCONNECTION_GETFD(srv->stat_cache->fam), FDEVENT_IN);
-+ }
-+#endif
-+
-+
-+ /* get the current number of FDs */
-+ srv->cur_fds = open("/dev/null", O_RDONLY);
-+ close(srv->cur_fds);
-+
-+ for (i = 0; i < srv->srv_sockets.used; i++) {
-+ server_socket *srv_socket = srv->srv_sockets.ptr[i];
-+ if (-1 == fdevent_fcntl_set(srv->ev, srv_socket->fd)) {
-+ log_error_write(srv, __FILE__, __LINE__, "ss", "fcntl failed:", strerror(errno));
-+ return -1;
-+ }
-+ }
-+
-+ /* Close stderr ASAP to make sure that nothing is being written to
-+ * that fd which may not be valid anymore after forking. */
-+ if (-1 == log_error_open(srv)) {
-+ log_error_write(srv, __FILE__, __LINE__, "s", "Opening errorlog failed. Going down.");
-+
-+ plugins_free(srv);
-+ network_close(srv);
-+ server_free(srv);
-+ return -1;
-+ }
-+
-+#ifdef HAVE_FORK
-+ /* network is up, let's deamonize ourself */
-+ if (srv->srvconf.dont_daemonize == 0) daemonize();
-+#endif
-
-+ /* write pid file */
-+ if (pid_fd != -1) {
-+ buffer_copy_long(srv->tmp_buf, getpid());
-+ buffer_append_string_len(srv->tmp_buf, CONST_STR_LEN("\n"));
-+ write(pid_fd, srv->tmp_buf->ptr, srv->tmp_buf->used - 1);
-+ close(pid_fd);
-+ pid_fd = -1;
-+ }
-
-
- #ifdef HAVE_SIGACTION
-@@ -1042,62 +1096,6 @@
- }
- #endif
-
-- if (NULL == (srv->ev = fdevent_init(srv->max_fds + 1, srv->event_handler))) {
-- log_error_write(srv, __FILE__, __LINE__,
-- "s", "fdevent_init failed");
-- return -1;
-- }
-- /*
-- * kqueue() is called here, select resets its internals,
-- * all server sockets get their handlers
-- *
-- * */
-- if (0 != network_register_fdevents(srv)) {
-- plugins_free(srv);
-- network_close(srv);
-- server_free(srv);
--
-- return -1;
-- }
--
-- /* might fail if user is using fam (not gamin) and famd isn't running */
-- if (NULL == (srv->stat_cache = stat_cache_init())) {
-- log_error_write(srv, __FILE__, __LINE__, "s",
-- "stat-cache could not be setup, dieing.");
-- return -1;
-- }
--
--#ifdef HAVE_FAM_H
-- /* setup FAM */
-- if (srv->srvconf.stat_cache_engine == STAT_CACHE_ENGINE_FAM) {
-- if (0 != FAMOpen2(srv->stat_cache->fam, "lighttpd")) {
-- log_error_write(srv, __FILE__, __LINE__, "s",
-- "could not open a fam connection, dieing.");
-- return -1;
-- }
--#ifdef HAVE_FAMNOEXISTS
-- FAMNoExists(srv->stat_cache->fam);
--#endif
--
-- srv->stat_cache->fam_fcce_ndx = -1;
-- fdevent_register(srv->ev, FAMCONNECTION_GETFD(srv->stat_cache->fam), stat_cache_handle_fdevent, NULL);
-- fdevent_event_add(srv->ev, &(srv->stat_cache->fam_fcce_ndx), FAMCONNECTION_GETFD(srv->stat_cache->fam), FDEVENT_IN);
-- }
--#endif
--
--
-- /* get the current number of FDs */
-- srv->cur_fds = open("/dev/null", O_RDONLY);
-- close(srv->cur_fds);
--
-- for (i = 0; i < srv->srv_sockets.used; i++) {
-- server_socket *srv_socket = srv->srv_sockets.ptr[i];
-- if (-1 == fdevent_fcntl_set(srv->ev, srv_socket->fd)) {
-- log_error_write(srv, __FILE__, __LINE__, "ss", "fcntl failed:", strerror(errno));
-- return -1;
-- }
-- }
--
- /* main-loop */
- while (!srv_shutdown) {
- int n;
================================================================
---- gitweb:
http://git.pld-linux.org/gitweb.cgi/packages/lighttpd.git/commitdiff/b429b3cce05773992b05cc6a547662a7fc2ed100
More information about the pld-cvs-commit
mailing list