Browse Source

hotplug2: enhanced dietlib patch to also address the usleep/nanosleep issue.

user/karasz/next/postgresql
Nagy Karoly Gabriel 14 years ago
parent
commit
e3df7baebc
  1. 25
      base/hotplug2/dietlibc.patch

25
base/hotplug2/dietlibc.patch

@ -1,3 +1,19 @@
# --- SDE-COPYRIGHT-NOTE-BEGIN ---
# This copyright note is auto-generated by ./scripts/Create-CopyPatch.
#
# Filename: package/.../hotplug2/dietlibc.patch
# Copyright (C) 2010 The OpenSDE Project
#
# More information can be found in the files COPYING and README.
#
# This patch file is dual-licensed. It is available under the license the
# patched project is licensed under, as long as it is an OpenSource license
# as defined at http://www.opensource.org/ (e.g. BSD, X11) or under the terms
# of the GNU General Public License as published by the Free Software
# Foundation; either version 2 of the License, or (at your option) any later
# version.
# --- SDE-COPYRIGHT-NOTE-END ---
--- ./hotplug2.c.orig 2007-08-15 16:36:03.000000000 -0400
+++ ./hotplug2.c 2007-08-15 16:39:05.000000000 -0400
@@ -13,6 +13,7 @@
@ -18,3 +34,12 @@
#define TERMCONDITION (persistent == 0 && \
coldplug_p == FORK_FINISHED && \
child == NULL && \
@@ -553,7 +557,7 @@
* their numbers.
*/
while (child_c >= max_child_c) {
- usleep(HOTPLUG2_THROTTLE_INTERVAL);
+ nanosleep(&((struct timespec){0,(HOTPLUG2_THROTTLE_INTERVAL) * 1000ul}), NULL);
}
sigemptyset(&block_mask);

Loading…
Cancel
Save