Skip to Content.
Sympa Menu

sm-commit - [SM-Commit] GIT changes to master grimoire by Vlad Glagolev (cd057c12cbb1074a2a2ef39c8ca84f16ab21d8bb)

sm-commit AT lists.ibiblio.org

Subject: Source Mage code commit list

List archive

Chronological Thread  
  • From: Vlad Glagolev <scm AT sourcemage.org>
  • To: sm-commit AT lists.ibiblio.org
  • Subject: [SM-Commit] GIT changes to master grimoire by Vlad Glagolev (cd057c12cbb1074a2a2ef39c8ca84f16ab21d8bb)
  • Date: Tue, 6 Jan 2015 17:49:04 -0600

GIT changes to master grimoire by Vlad Glagolev <stealth AT sourcemage.org>:

net/monit/BUILD | 8 +++++---
net/monit/DETAILS | 1 +
net/monit/HISTORY | 6 ++++++
net/monit/PRE_BUILD | 4 ++++
net/monit/timeout.patch | 20 ++++++++++++++++++++
5 files changed, 36 insertions(+), 3 deletions(-)

New commits:
commit cd057c12cbb1074a2a2ef39c8ca84f16ab21d8bb
Author: Vlad Glagolev <stealth AT sourcemage.org>
Commit: Vlad Glagolev <stealth AT sourcemage.org>

monit: post-update fixes

diff --git a/net/monit/BUILD b/net/monit/BUILD
index 4a78efb..c0a255a 100755
--- a/net/monit/BUILD
+++ b/net/monit/BUILD
@@ -1,3 +1,5 @@
-OPTS="--bindir=$INSTALL_ROOT/sbin $OPTS" &&
-default_build_configure &&
-default_build_make
+OPTS="--bindir=$INSTALL_ROOT/sbin \
+ --sysconfdir=$INSTALL_ROOT/etc/sysconfig \
+ $OPTS" &&
+
+default_build
diff --git a/net/monit/DETAILS b/net/monit/DETAILS
index b9726fa..f2dd973 100755
--- a/net/monit/DETAILS
+++ b/net/monit/DETAILS
@@ -1,5 +1,6 @@
SPELL=monit
VERSION=5.11
+ PATCHLEVEL=1
SOURCE="${SPELL}-${VERSION}.tar.gz"
SOURCE_URL[0]="http://mmonit.com/${SPELL}/dist/${SOURCE}";

SOURCE_HASH=sha512:d3bffd0fa5326d7783259af5f14beaed510d06644ec865e933e63aab2c35d47e2f859a9e490b0193ae62c9174a065c216cfa0ae3708d5a06a2d92e9c384f4151
diff --git a/net/monit/HISTORY b/net/monit/HISTORY
index 44bbcb8..9c8e61d 100644
--- a/net/monit/HISTORY
+++ b/net/monit/HISTORY
@@ -1,3 +1,9 @@
+2015-01-07 Vlad Glagolev <stealth AT sourcemage.org>
+ * DETAILS: PATCHLEVEL=1
+ * BUILD: use default_build; use /etc/sysconfig as sysconfdir for
monitrc
+ * PRE_BUILD: to apply the patch
+ * timeout.patch: added, official patches, to fix icmp timeout value
+
2015-01-05 Vlad Glagolev <stealth AT sourcemage.org>
* DETAILS: updated spell to 5.11

diff --git a/net/monit/PRE_BUILD b/net/monit/PRE_BUILD
new file mode 100755
index 0000000..f046935
--- /dev/null
+++ b/net/monit/PRE_BUILD
@@ -0,0 +1,4 @@
+default_pre_build &&
+cd "$SOURCE_DIRECTORY" &&
+
+patch -p0 < "$SPELL_DIRECTORY/timeout.patch"
diff --git a/net/monit/timeout.patch b/net/monit/timeout.patch
new file mode 100644
index 0000000..b21db81
--- /dev/null
+++ b/net/monit/timeout.patch
@@ -0,0 +1,20 @@
+--- src/net.c.orig 2014-12-22 21:41:37.000000000 +0300
++++ src/net.c 2015-01-07 01:23:01.461108587 +0300
+@@ -515,7 +515,7 @@
+ gettimeofday(&t_in, NULL);
+ /* The read from connection-less raw socket via
recvfrom() provides messages regardless of origin, the source IP address is
set in sout, we have to check the IP and skip responses belonging to other
ICMP conversations */
+ if (sout.sin_addr.s_addr != sa->sin_addr.s_addr ||
icmpin->icmp_type != ICMP_ECHOREPLY || id_in != id_out || seq_in >=
(uint16_t)count) {
+- if ((read_timeout = timeout - ((t_in.tv_sec
- t_out.tv_sec) + (t_in.tv_usec - t_out.tv_usec) / 1000.)) > 0)
++ if ((read_timeout = timeout - ((t_in.tv_sec
- t_out.tv_sec) * 1000 + (t_in.tv_usec - t_out.tv_usec) / 1000.)) > 0)
+ goto readnext; // Try to read next
packet, but don't exceed the timeout while waiting for our response so we
won't loop forever if the socket is flooded with other ICMP packets
+ } else {
+ data = (unsigned char *)icmpin->icmp_data;
+@@ -525,7 +525,7 @@
+ break; // Wait for one response only
+ }
+ } else
+- LogError("Ping response for %s %d/%d timed out --
no response within %d seconds\n", hostname, i + 1, count, timeout);
++ LogError("Ping response for %s %d/%d timed out --
no response within %d seconds\n", hostname, i + 1, count, timeout / 1000);
+ }
+ error1:
+ do {



  • [SM-Commit] GIT changes to master grimoire by Vlad Glagolev (cd057c12cbb1074a2a2ef39c8ca84f16ab21d8bb), Vlad Glagolev, 01/06/2015

Archive powered by MHonArc 2.6.24.

Top of Page