pkgsrc-Changes archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

CVS commit: pkgsrc/net/paris-traceroute



Module Name:    pkgsrc
Committed By:   joerg
Date:           Fri Mar 27 20:52:20 UTC 2020

Modified Files:
        pkgsrc/net/paris-traceroute: distinfo
        pkgsrc/net/paris-traceroute/patches: patch-src_Util.cc
Added Files:
        pkgsrc/net/paris-traceroute/patches: patch-src_ConcurrentTracert.cc
            patch-src_ExhaustiveOldTracert.cc patch-src_ExhaustiveTracert.cc
            patch-src_HopByHopTracert.cc patch-src_ICMPDestUnreachable.cc
            patch-src_ICMPEcho.cc patch-src_ICMPHeader.cc
            patch-src_ICMPProbe.cc patch-src_ICMPReply.cc
            patch-src_ICMPTimeExceeded.cc patch-src_IP4Header.cc
            patch-src_IP4Header__NetBSD.cc patch-src_MPLSHeader.cc
            patch-src_MihScannerTracert.cc patch-src_NULLTracert.cc
            patch-src_Options.cc patch-src_PackByPackTracert.cc
            patch-src_Reply.cc patch-src_ScoutTracert.cc patch-src_Server.cc
            patch-src_TCPHeader.cc patch-src_TCPProbe.cc patch-src_TCPReply.cc
            patch-src_TracertImpl.cc patch-src_UDPHeader.cc
            patch-src_UDPProbe.cc patch-src_Util__NetBSD.cc patch-src_common.h
            patch-src_paris-traceroute.cc patch-src_tupleroute.cc

Log Message:
Rename log to mylog to avoid conflict with math.h.


To generate a diff of this commit:
cvs rdiff -u -r1.3 -r1.4 pkgsrc/net/paris-traceroute/distinfo
cvs rdiff -u -r0 -r1.1 \
    pkgsrc/net/paris-traceroute/patches/patch-src_ConcurrentTracert.cc \
    pkgsrc/net/paris-traceroute/patches/patch-src_ExhaustiveOldTracert.cc \
    pkgsrc/net/paris-traceroute/patches/patch-src_ExhaustiveTracert.cc \
    pkgsrc/net/paris-traceroute/patches/patch-src_HopByHopTracert.cc \
    pkgsrc/net/paris-traceroute/patches/patch-src_ICMPDestUnreachable.cc \
    pkgsrc/net/paris-traceroute/patches/patch-src_ICMPEcho.cc \
    pkgsrc/net/paris-traceroute/patches/patch-src_ICMPHeader.cc \
    pkgsrc/net/paris-traceroute/patches/patch-src_ICMPProbe.cc \
    pkgsrc/net/paris-traceroute/patches/patch-src_ICMPReply.cc \
    pkgsrc/net/paris-traceroute/patches/patch-src_ICMPTimeExceeded.cc \
    pkgsrc/net/paris-traceroute/patches/patch-src_IP4Header.cc \
    pkgsrc/net/paris-traceroute/patches/patch-src_IP4Header__NetBSD.cc \
    pkgsrc/net/paris-traceroute/patches/patch-src_MPLSHeader.cc \
    pkgsrc/net/paris-traceroute/patches/patch-src_MihScannerTracert.cc \
    pkgsrc/net/paris-traceroute/patches/patch-src_NULLTracert.cc \
    pkgsrc/net/paris-traceroute/patches/patch-src_Options.cc \
    pkgsrc/net/paris-traceroute/patches/patch-src_PackByPackTracert.cc \
    pkgsrc/net/paris-traceroute/patches/patch-src_Reply.cc \
    pkgsrc/net/paris-traceroute/patches/patch-src_ScoutTracert.cc \
    pkgsrc/net/paris-traceroute/patches/patch-src_Server.cc \
    pkgsrc/net/paris-traceroute/patches/patch-src_TCPHeader.cc \
    pkgsrc/net/paris-traceroute/patches/patch-src_TCPProbe.cc \
    pkgsrc/net/paris-traceroute/patches/patch-src_TCPReply.cc \
    pkgsrc/net/paris-traceroute/patches/patch-src_TracertImpl.cc \
    pkgsrc/net/paris-traceroute/patches/patch-src_UDPHeader.cc \
    pkgsrc/net/paris-traceroute/patches/patch-src_UDPProbe.cc \
    pkgsrc/net/paris-traceroute/patches/patch-src_Util__NetBSD.cc \
    pkgsrc/net/paris-traceroute/patches/patch-src_common.h \
    pkgsrc/net/paris-traceroute/patches/patch-src_paris-traceroute.cc \
    pkgsrc/net/paris-traceroute/patches/patch-src_tupleroute.cc
cvs rdiff -u -r1.1 -r1.2 \
    pkgsrc/net/paris-traceroute/patches/patch-src_Util.cc

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: pkgsrc/net/paris-traceroute/distinfo
diff -u pkgsrc/net/paris-traceroute/distinfo:1.3 pkgsrc/net/paris-traceroute/distinfo:1.4
--- pkgsrc/net/paris-traceroute/distinfo:1.3    Wed Nov  4 00:35:26 2015
+++ pkgsrc/net/paris-traceroute/distinfo        Fri Mar 27 20:52:19 2020
@@ -1,7 +1,37 @@
-$NetBSD: distinfo,v 1.3 2015/11/04 00:35:26 agc Exp $
+$NetBSD: distinfo,v 1.4 2020/03/27 20:52:19 joerg Exp $
 
 SHA1 (paris-traceroute-0.92-dev.tar.gz) = 83096a5bbc58329633407db040ece2af21954f6b
 RMD160 (paris-traceroute-0.92-dev.tar.gz) = 05fb22f0d8138950eb73ab69adf3c2d2cb50ff03
 SHA512 (paris-traceroute-0.92-dev.tar.gz) = ecae447bb3f811f5668d2beb24fb0146e9267189e14c10b09fe930daad552e97dbcde7208be6020c83b3560b41395a866a87d4076e6ce6c5d574490a9e0d9128
 Size (paris-traceroute-0.92-dev.tar.gz) = 1063191 bytes
-SHA1 (patch-src_Util.cc) = a46a3318bf8fd5325bf62f1040370f525824e034
+SHA1 (patch-src_ConcurrentTracert.cc) = 411c26a3599056908e92b54e5bb553f1bd1569af
+SHA1 (patch-src_ExhaustiveOldTracert.cc) = 3b726ea4894b6753d87631db48eeaf31c853f967
+SHA1 (patch-src_ExhaustiveTracert.cc) = 41171f5789d5700cd84e263ba508295b26c912b0
+SHA1 (patch-src_HopByHopTracert.cc) = 756aeb7db69aaa04165aad3b27ed5531331a3d51
+SHA1 (patch-src_ICMPDestUnreachable.cc) = ade361797bbf4b256d43a3462e29bae0326d7ed6
+SHA1 (patch-src_ICMPEcho.cc) = d74e1a011520249888a5cb1bc1de0bc65576016c
+SHA1 (patch-src_ICMPHeader.cc) = 8f859cb9938669a15ce16dede5efb90aa6b0eab6
+SHA1 (patch-src_ICMPProbe.cc) = 598eb55d84fb9f53091b14eb13ebacaec44f3bb2
+SHA1 (patch-src_ICMPReply.cc) = cb01a8d300784cedb555917ac766ed0285aee7ac
+SHA1 (patch-src_ICMPTimeExceeded.cc) = 21192c307fcf635808ebafcfc1c5184d4b9c6d22
+SHA1 (patch-src_IP4Header.cc) = 116771fd348c8065409a1e77e4cfe8f296a8511b
+SHA1 (patch-src_IP4Header__NetBSD.cc) = 9b369b437493eb746f9b39176ef73494513a6856
+SHA1 (patch-src_MPLSHeader.cc) = 13f4319f321d73175781793283486ea6d4b689df
+SHA1 (patch-src_MihScannerTracert.cc) = 065f91c51fec7a041c4588b7ad59ed31398299fc
+SHA1 (patch-src_NULLTracert.cc) = d75ac4b3c91d8d774b52bf1ffc43d4540ca742e7
+SHA1 (patch-src_Options.cc) = fd8c0fdc44c140d32ee211ddf2347b7cdc5e9ac4
+SHA1 (patch-src_PackByPackTracert.cc) = 058fa4f419f6c7e7f27d3d9b0e7531c4177a813b
+SHA1 (patch-src_Reply.cc) = d5194545728f4220d16886eb3940270b868c2133
+SHA1 (patch-src_ScoutTracert.cc) = 30e5dd549f592cdee26f8174a2800b6ae42c83be
+SHA1 (patch-src_Server.cc) = 32b1a406d449b958b788bbfd3a6e7721a11701b3
+SHA1 (patch-src_TCPHeader.cc) = 98f1951db359c80d6ab55fec919c6424c6a2b486
+SHA1 (patch-src_TCPProbe.cc) = d8e62afba4a570668b225d1018a662b669c08dbf
+SHA1 (patch-src_TCPReply.cc) = 3d115dadaf1fcf4ef27391ceba0324e0c82c4ff2
+SHA1 (patch-src_TracertImpl.cc) = 7e74f90175095b4903727ff7f14634a482e4f64e
+SHA1 (patch-src_UDPHeader.cc) = ee04ffec773f790d949575ee00d9b57febd52bb8
+SHA1 (patch-src_UDPProbe.cc) = a70e18583f5e4d7f77cc60bc5b7c880a8ff4aa9a
+SHA1 (patch-src_Util.cc) = f079a15ed07ff68705f4a09be3fafa8adbe70e86
+SHA1 (patch-src_Util__NetBSD.cc) = 481daa18bcf68042cb17e4910d146f4768dcf263
+SHA1 (patch-src_common.h) = 0f71af6b6138313cf43259daa7302cf1d6744439
+SHA1 (patch-src_paris-traceroute.cc) = 84b8b096628f9356b66360f5372ca77091787804
+SHA1 (patch-src_tupleroute.cc) = 3507e5c3902964f2afa6ce5d8103467a4d62f30e

Index: pkgsrc/net/paris-traceroute/patches/patch-src_Util.cc
diff -u pkgsrc/net/paris-traceroute/patches/patch-src_Util.cc:1.1 pkgsrc/net/paris-traceroute/patches/patch-src_Util.cc:1.2
--- pkgsrc/net/paris-traceroute/patches/patch-src_Util.cc:1.1   Thu Sep 25 16:08:24 2014
+++ pkgsrc/net/paris-traceroute/patches/patch-src_Util.cc       Fri Mar 27 20:52:19 2020
@@ -1,4 +1,4 @@
-$NetBSD: patch-src_Util.cc,v 1.1 2014/09/25 16:08:24 jperkin Exp $
+$NetBSD: patch-src_Util.cc,v 1.2 2020/03/27 20:52:19 joerg Exp $
 
 SunOS needs strings.h for bzero().
 
@@ -14,3 +14,36 @@ SunOS needs strings.h for bzero().
  #include <unistd.h>
  //#include <asm/types.h>
  #include <sys/ioctl.h>
+@@ -89,7 +92,7 @@ Util::getRoute (const char* dest) {
+   fscanf(fd, "%s", buff);
+   pclose(fd);
+ 
+-  log(INFO, "Source address = %s\n", buff);
++  mylog(INFO, "Source address = %s\n", buff);
+ 
+   return strdup(buff);
+ }
+@@ -243,7 +246,7 @@ Util::write32 (uint8* data, int ofs, uin
+ int
+ Util::protocol2int (const char* protocol) {
+   struct protoent* proto = getprotobyname(protocol);
+-  log(DUMP, "p_proto = %d", proto->p_proto);
++  mylog(DUMP, "p_proto = %d", proto->p_proto);
+   return proto->p_proto;
+ }
+ 
+@@ -278,12 +281,12 @@ Util::my_gethostbyname(char* host) {
+    struct hostent* phost = gethostbyname(host);
+    if (phost == NULL || phost->h_addrtype != AF_INET) {
+      // Not a valid IP4 address
+-     log(ERROR, "Invalid address");
++     mylog(ERROR, "Invalid address");
+      return NULL;
+    }
+    struct in_addr *buff = (in_addr*)phost->h_addr_list[0];
+    char* dst_addr = strdup(inet_ntoa(*buff));
+-   log(DUMP, "dst_addr = %s", dst_addr);
++   mylog(DUMP, "dst_addr = %s", dst_addr);
+    return dst_addr;
+  }
+ }

Added files:

Index: pkgsrc/net/paris-traceroute/patches/patch-src_ConcurrentTracert.cc
diff -u /dev/null pkgsrc/net/paris-traceroute/patches/patch-src_ConcurrentTracert.cc:1.1
--- /dev/null   Fri Mar 27 20:52:20 2020
+++ pkgsrc/net/paris-traceroute/patches/patch-src_ConcurrentTracert.cc  Fri Mar 27 20:52:19 2020
@@ -0,0 +1,21 @@
+$NetBSD: patch-src_ConcurrentTracert.cc,v 1.1 2020/03/27 20:52:19 joerg Exp $
+
+--- src/ConcurrentTracert.cc.orig      2020-03-27 18:19:16.969383442 +0000
++++ src/ConcurrentTracert.cc
+@@ -19,7 +19,7 @@ ConcurrentTracert::ConcurrentTracert (Op
+ 
+   ttl_max = ttl;
+   
+-  log(INFO, "Concurrent algo");
++  mylog(INFO, "Concurrent algo");
+ }
+ 
+ ConcurrentTracert::~ConcurrentTracert () {
+@@ -117,6 +117,6 @@ ConcurrentTracert::getMaxTTL () {
+ 
+ uint8
+ ConcurrentTracert::getNbrReplies(uint8 ttl) {
+-  log(WARN, "TODO");
++  mylog(WARN, "TODO");
+   return 0;
+ }
Index: pkgsrc/net/paris-traceroute/patches/patch-src_ExhaustiveOldTracert.cc
diff -u /dev/null pkgsrc/net/paris-traceroute/patches/patch-src_ExhaustiveOldTracert.cc:1.1
--- /dev/null   Fri Mar 27 20:52:20 2020
+++ pkgsrc/net/paris-traceroute/patches/patch-src_ExhaustiveOldTracert.cc       Fri Mar 27 20:52:19 2020
@@ -0,0 +1,31 @@
+$NetBSD: patch-src_ExhaustiveOldTracert.cc,v 1.1 2020/03/27 20:52:19 joerg Exp $
+
+--- src/ExhaustiveOldTracert.cc.orig   2020-03-27 18:19:24.295954828 +0000
++++ src/ExhaustiveOldTracert.cc
+@@ -20,7 +20,7 @@
+  * @param opts List of options
+  */
+ ExhaustiveOldTracert::ExhaustiveOldTracert (Options* opts, bool per_dest) : TracertImpl(opts) {
+-  log(INFO, "Exhaustive algo");
++  mylog(INFO, "Exhaustive algo");
+   this->per_dest = per_dest;
+ }
+ 
+@@ -467,7 +467,7 @@ ExhaustiveOldTracert::trace (char* targe
+     missing = (nbr_replies_received == 0) ? (missing + 1) : 0;
+ 
+     if (missing >= opts->max_missing) {
+-      log(INFO, "Too many down hops -> stop algo");
++      mylog(INFO, "Too many down hops -> stop algo");
+       //pthread_mutex_unlock(&lock);
+       stop_algo = true;
+     }
+@@ -607,7 +607,7 @@ ExhaustiveOldTracert::notifyReply (Reply
+ 
+   //printf("valide!\n");
+   // The reply is OK, update the timed probe associated to it
+-  log(INFO, "Valid reply, id=%x", reply->getID());
++  mylog(INFO, "Valid reply, id=%x", reply->getID());
+   
+   updateInfos(tprobe, reply);
+   
Index: pkgsrc/net/paris-traceroute/patches/patch-src_ExhaustiveTracert.cc
diff -u /dev/null pkgsrc/net/paris-traceroute/patches/patch-src_ExhaustiveTracert.cc:1.1
--- /dev/null   Fri Mar 27 20:52:20 2020
+++ pkgsrc/net/paris-traceroute/patches/patch-src_ExhaustiveTracert.cc  Fri Mar 27 20:52:19 2020
@@ -0,0 +1,53 @@
+$NetBSD: patch-src_ExhaustiveTracert.cc,v 1.1 2020/03/27 20:52:19 joerg Exp $
+
+--- src/ExhaustiveTracert.cc.orig      2020-03-27 18:19:26.755600510 +0000
++++ src/ExhaustiveTracert.cc
+@@ -22,7 +22,7 @@
+  * @param opts List of options
+  */
+ ExhaustiveTracert::ExhaustiveTracert (Options* opts, bool     per_dest) : TracertImpl(opts) {
+-  log(INFO, "Exhaustive algo");
++  mylog(INFO, "Exhaustive algo");
+   this->per_dest = per_dest;
+ }
+ 
+@@ -494,7 +494,7 @@ ExhaustiveTracert::trace (char* target, 
+     missing = (nbr_replies_received == 0) ? (missing + 1) : 0;
+ 
+     if (missing >= opts->max_missing) {
+-      log(INFO, "Too many down hops -> stop algo");
++      mylog(INFO, "Too many down hops -> stop algo");
+       //pthread_mutex_unlock(&lock);
+       stop_algo = true;
+     }
+@@ -626,7 +626,7 @@ ExhaustiveTracert::notifyReply (Reply* r
+ 
+   //printf("valide!\n");
+   // The reply is OK, update the timed probe associated to it
+-  log(INFO, "Valid reply, id=%x", reply->getID());
++  mylog(INFO, "Valid reply, id=%x", reply->getID());
+   
+   updateInfos(tprobe, reply);
+   
+@@ -638,7 +638,7 @@ ExhaustiveTracert::notifyReply (Reply* r
+   if (tprobe->classif_expected_addr == 0) {
+       Interface* interf = add_interface(current_mprobes, tprobe->host_address_raw);
+     //if (opts->debug)
+-    //  log(WARN, "[%d] new interface : %s", ttl_current, tprobe->host_address);
++    //  mylog(WARN, "[%d] new interface : %s", ttl_current, tprobe->host_address);
+       
+       tprobe->interf = interf;
+       //printf("current_mprobes->backward_update %d\n", current_mprobes->backward_update);
+@@ -666,10 +666,10 @@ ExhaustiveTracert::notifyReply (Reply* r
+         //struct in_addr host_addr;
+                               //host_addr.s_addr         = tprobe->classif_expected_addr;
+                               //char* host_address     = inet_ntoa(host_addr);
+-        log(WARN, "[%d] %s NOT per-flow, expected %s", ttl_current, tprobe->host_address, Util::my_inet_ntoa(tprobe->classif_expected_addr));
++        mylog(WARN, "[%d] %s NOT per-flow, expected %s", ttl_current, tprobe->host_address, Util::my_inet_ntoa(tprobe->classif_expected_addr));
+               }
+       }/* else {
+-              log(WARN, "[%d] %s per-flow, expected %s", ttl_current, tprobe->host_address, my_inet_ntoa(tprobe->classif_expected_addr));
++              mylog(WARN, "[%d] %s per-flow, expected %s", ttl_current, tprobe->host_address, my_inet_ntoa(tprobe->classif_expected_addr));
+       }*/
+   }
+   
Index: pkgsrc/net/paris-traceroute/patches/patch-src_HopByHopTracert.cc
diff -u /dev/null pkgsrc/net/paris-traceroute/patches/patch-src_HopByHopTracert.cc:1.1
--- /dev/null   Fri Mar 27 20:52:20 2020
+++ pkgsrc/net/paris-traceroute/patches/patch-src_HopByHopTracert.cc    Fri Mar 27 20:52:19 2020
@@ -0,0 +1,21 @@
+$NetBSD: patch-src_HopByHopTracert.cc,v 1.1 2020/03/27 20:52:19 joerg Exp $
+
+--- src/HopByHopTracert.cc.orig        2020-03-27 18:19:29.074226888 +0000
++++ src/HopByHopTracert.cc
+@@ -104,7 +104,7 @@ HopByHopTracert::trace (char* target, in
+     missing = (nbr_replies_received == 0) ? (missing + 1) : 0;
+ 
+     if (missing >= opts->max_missing) {
+-      log(INFO, "Too many down hops -> stop algo");
++      mylog(INFO, "Too many down hops -> stop algo");
+       //pthread_mutex_unlock(&lock);
+       stop_algo = true;
+     }
+@@ -126,6 +126,6 @@ HopByHopTracert::trace (char* target, in
+ 
+ uint8
+ HopByHopTracert::getNbrReplies(uint8 ttl) {
+-  log(WARN, "TODO");
++  mylog(WARN, "TODO");
+   return 0;
+ }
Index: pkgsrc/net/paris-traceroute/patches/patch-src_ICMPDestUnreachable.cc
diff -u /dev/null pkgsrc/net/paris-traceroute/patches/patch-src_ICMPDestUnreachable.cc:1.1
--- /dev/null   Fri Mar 27 20:52:20 2020
+++ pkgsrc/net/paris-traceroute/patches/patch-src_ICMPDestUnreachable.cc        Fri Mar 27 20:52:19 2020
@@ -0,0 +1,26 @@
+$NetBSD: patch-src_ICMPDestUnreachable.cc,v 1.1 2020/03/27 20:52:19 joerg Exp $
+
+--- src/ICMPDestUnreachable.cc.orig    2020-03-27 18:19:31.352092281 +0000
++++ src/ICMPDestUnreachable.cc
+@@ -82,14 +82,14 @@ ICMPDestUnreachable::getHeaderLength () 
+  */
+ void
+ ICMPDestUnreachable::dump () {
+-  log(DUMP, "ICMP Time Exceeded Header :\n");
+-  log(DUMP, "type                = %s\n", getTypeDesc());
+-  log(DUMP, "code                = %s\n", getCodeDesc());
+-  log(DUMP, "checksum            = %d\n", getChecksum());
+-  log(DUMP, "bytes 4-7           = 0x%x\n", *(uint32*)(header+4));
+-  log(DUMP, "Erroneous IP4 header :\n");
++  mylog(DUMP, "ICMP Time Exceeded Header :\n");
++  mylog(DUMP, "type                = %s\n", getTypeDesc());
++  mylog(DUMP, "code                = %s\n", getCodeDesc());
++  mylog(DUMP, "checksum            = %d\n", getChecksum());
++  mylog(DUMP, "bytes 4-7           = 0x%x\n", *(uint32*)(header+4));
++  mylog(DUMP, "Erroneous IP4 header :\n");
+   ip4_err->dump();
+-  log(DUMP, "Erroneous data :\n");
++  mylog(DUMP, "Erroneous data :\n");
+   dumpRawData(DUMP, data_err, 8);
+ }
+ 
Index: pkgsrc/net/paris-traceroute/patches/patch-src_ICMPEcho.cc
diff -u /dev/null pkgsrc/net/paris-traceroute/patches/patch-src_ICMPEcho.cc:1.1
--- /dev/null   Fri Mar 27 20:52:20 2020
+++ pkgsrc/net/paris-traceroute/patches/patch-src_ICMPEcho.cc   Fri Mar 27 20:52:19 2020
@@ -0,0 +1,22 @@
+$NetBSD: patch-src_ICMPEcho.cc,v 1.1 2020/03/27 20:52:19 joerg Exp $
+
+--- src/ICMPEcho.cc.orig       2020-03-27 18:19:34.138799353 +0000
++++ src/ICMPEcho.cc
+@@ -91,11 +91,11 @@ ICMPEcho::getHeaderLength () {
+  */
+ void
+ ICMPEcho::dump () {
+-  log(DUMP, "ICMP Echo header :\n");
+-  log(DUMP, "type                = %s\n", getTypeDesc());
+-  log(DUMP, "code                = %s\n", getCodeDesc());
+-  log(DUMP, "checksum            = %d\n", getChecksum());
+-  log(DUMP, "identifier          = %d\n", getIdentifier());
+-  log(DUMP, "sequence            = %d\n", getSequence());
++  mylog(DUMP, "ICMP Echo header :\n");
++  mylog(DUMP, "type                = %s\n", getTypeDesc());
++  mylog(DUMP, "code                = %s\n", getCodeDesc());
++  mylog(DUMP, "checksum            = %d\n", getChecksum());
++  mylog(DUMP, "identifier          = %d\n", getIdentifier());
++  mylog(DUMP, "sequence            = %d\n", getSequence());
+ }
+ 
Index: pkgsrc/net/paris-traceroute/patches/patch-src_ICMPHeader.cc
diff -u /dev/null pkgsrc/net/paris-traceroute/patches/patch-src_ICMPHeader.cc:1.1
--- /dev/null   Fri Mar 27 20:52:20 2020
+++ pkgsrc/net/paris-traceroute/patches/patch-src_ICMPHeader.cc Fri Mar 27 20:52:19 2020
@@ -0,0 +1,32 @@
+$NetBSD: patch-src_ICMPHeader.cc,v 1.1 2020/03/27 20:52:19 joerg Exp $
+
+--- src/ICMPHeader.cc.orig     2020-03-27 18:19:36.461356104 +0000
++++ src/ICMPHeader.cc
+@@ -241,12 +241,12 @@ ICMPHeader::pack (uint8* data, int lengt
+  */
+ void
+ ICMPHeader::dump () {
+-  log(DUMP, "ICMP Header :");
+-  log(DUMP, "type                = %s", getTypeDesc());
+-  log(DUMP, "code                = %s", getCodeDesc());
+-  log(DUMP, "checksum            = %d", getChecksum());
+-  log(DUMP, "identifier          = %d", getIdentifier());
+-  log(DUMP, "sequence            = %d", getSequence());
++  mylog(DUMP, "ICMP Header :");
++  mylog(DUMP, "type                = %s", getTypeDesc());
++  mylog(DUMP, "code                = %s", getCodeDesc());
++  mylog(DUMP, "checksum            = %d", getChecksum());
++  mylog(DUMP, "identifier          = %d", getIdentifier());
++  mylog(DUMP, "sequence            = %d", getSequence());
+ }
+ 
+ /**
+@@ -254,7 +254,7 @@ ICMPHeader::dump () {
+  */
+ void
+ ICMPHeader::dumpRaw () {
+-  log(DUMP, "ICMP Header :\n");
++  mylog(DUMP, "ICMP Header :\n");
+   dumpRawData(WARN, header, header_len);
+ }
+ 
Index: pkgsrc/net/paris-traceroute/patches/patch-src_ICMPProbe.cc
diff -u /dev/null pkgsrc/net/paris-traceroute/patches/patch-src_ICMPProbe.cc:1.1
--- /dev/null   Fri Mar 27 20:52:20 2020
+++ pkgsrc/net/paris-traceroute/patches/patch-src_ICMPProbe.cc  Fri Mar 27 20:52:19 2020
@@ -0,0 +1,26 @@
+$NetBSD: patch-src_ICMPProbe.cc,v 1.1 2020/03/27 20:52:19 joerg Exp $
+
+--- src/ICMPProbe.cc.orig      2020-03-27 18:19:38.646376189 +0000
++++ src/ICMPProbe.cc
+@@ -124,10 +124,10 @@ ICMPProbe::getID () {
+  */
+ void
+ ICMPProbe::dump () {
+-  log(DUMP, "==> ICMP Probe :");
++  mylog(DUMP, "==> ICMP Probe :");
+   for (int i = 0; i  < getNbrHeaders(); i++)
+     getHeader(i)->dump();
+-  log(DUMP, "Data :");
++  mylog(DUMP, "Data :");
+   if (data != NULL)
+     dumpRawData(DUMP, data, data_length);
+ }
+@@ -140,7 +140,7 @@ ICMPProbe::dumpRaw () {
+   uint8* data;
+   int   length;
+   getDatagram(&data, &length);
+-  log(DUMP, "==> ICMP Probe :");
++  mylog(DUMP, "==> ICMP Probe :");
+   dumpRawData(DUMP, data, length);
+ }
+ 
Index: pkgsrc/net/paris-traceroute/patches/patch-src_ICMPReply.cc
diff -u /dev/null pkgsrc/net/paris-traceroute/patches/patch-src_ICMPReply.cc:1.1
--- /dev/null   Fri Mar 27 20:52:20 2020
+++ pkgsrc/net/paris-traceroute/patches/patch-src_ICMPReply.cc  Fri Mar 27 20:52:19 2020
@@ -0,0 +1,98 @@
+$NetBSD: patch-src_ICMPReply.cc,v 1.1 2020/03/27 20:52:19 joerg Exp $
+
+--- src/ICMPReply.cc.orig      2020-03-27 18:19:41.060175131 +0000
++++ src/ICMPReply.cc
+@@ -180,7 +180,7 @@ ICMPReply::getProcId () {
+         ICMPHeader* err_icmp = (ICMPHeader*)getHeader(3);
+         return err_icmp->getIdentifier();
+       } else { // Protocol not supported : return 0
+-        log(DUMP, "Protocol not supported");
++        mylog(DUMP, "Protocol not supported");
+         return 0;
+       }
+   }
+@@ -219,12 +219,12 @@ ICMPReply::getID () {
+         //return err_ip->getIPId();
+         return err_icmp->getSequence();
+       } else { // Protocol not supported : return 0
+-        log(DUMP, "Protocol not supported");
++        mylog(DUMP, "Protocol not supported");
+         return 0;
+       }
+ 
+   }
+-  log(DUMP, "Unsupported ICMP message");
++  mylog(DUMP, "Unsupported ICMP message");
+   return 0;
+ }
+ 
+@@ -233,29 +233,29 @@ ICMPReply::getID2 () {
+       ICMPHeader* icmp = (ICMPHeader*)getHeader(1);
+       switch (icmp->getType()) {
+     case 0x00:        // Echo reply
+-      log(WARN, "getID2 icmp reply TODO\n");
++      mylog(WARN, "getID2 icmp reply TODO\n");
+       return 0;
+     case 0x03:        // Port unreachable
+     case 0x0b:        // Time Exceeded
+       // Get Erroneous IPv4 header
+       IP4Header* err_ip = (IP4Header*)getHeader(2);
+       if (err_ip->getProtocol() == 6) { 
+-              log(WARN, "getID2 tcp TODO\n");
++              mylog(WARN, "getID2 tcp TODO\n");
+         return 0;
+       } else if (err_ip->getProtocol() == 17) {
+         UDPHeader* err_udp = (UDPHeader*)getHeader(3);
+         return err_udp->getChecksum();
+       } else if (err_ip->getProtocol() == 1) {
+-              log(WARN, "getID2, icmp err TODO\n");
++              mylog(WARN, "getID2, icmp err TODO\n");
+         ICMPHeader* err_icmp = (ICMPHeader*)getHeader(3);
+         return 0;
+       } else { // Protocol not supported : return 0
+-        log(DUMP, "Protocol not supported");
++        mylog(DUMP, "Protocol not supported");
+         return 0;
+       }
+ 
+   }
+-  log(DUMP, "Unsupported ICMP message");
++  mylog(DUMP, "Unsupported ICMP message");
+   return 0;
+ }
+ 
+@@ -264,29 +264,29 @@ ICMPReply::getID3 () {
+       ICMPHeader* icmp = (ICMPHeader*)getHeader(1);
+       switch (icmp->getType()) {
+     case 0x00:        // Echo reply
+-      log(WARN, "getID3 icmp reply TODO\n");
++      mylog(WARN, "getID3 icmp reply TODO\n");
+       return 0;
+     case 0x03:        // Port unreachable
+     case 0x0b:        // Time Exceeded
+       // Get Erroneous IPv4 header
+       IP4Header* err_ip = (IP4Header*)getHeader(2);
+       if (err_ip->getProtocol() == 6) { 
+-              log(WARN, "getID3 tcp TODO\n");
++              mylog(WARN, "getID3 tcp TODO\n");
+         return 0;
+       } else if (err_ip->getProtocol() == 17) {
+         UDPHeader* err_udp = (UDPHeader*)getHeader(3);
+         return err_udp->getDestPort();
+       } else if (err_ip->getProtocol() == 1) {
+-              log(WARN, "getID3, icmp err TODO\n");
++              mylog(WARN, "getID3, icmp err TODO\n");
+         ICMPHeader* err_icmp = (ICMPHeader*)getHeader(3);
+         return 0;
+       } else { // Protocol not supported : return 0
+-        log(DUMP, "Protocol not supported");
++        mylog(DUMP, "Protocol not supported");
+         return 0;
+       }
+ 
+   }
+-  log(DUMP, "Unsupported ICMP message");
++  mylog(DUMP, "Unsupported ICMP message");
+   return 0;
+ }
+ 
Index: pkgsrc/net/paris-traceroute/patches/patch-src_ICMPTimeExceeded.cc
diff -u /dev/null pkgsrc/net/paris-traceroute/patches/patch-src_ICMPTimeExceeded.cc:1.1
--- /dev/null   Fri Mar 27 20:52:20 2020
+++ pkgsrc/net/paris-traceroute/patches/patch-src_ICMPTimeExceeded.cc   Fri Mar 27 20:52:19 2020
@@ -0,0 +1,26 @@
+$NetBSD: patch-src_ICMPTimeExceeded.cc,v 1.1 2020/03/27 20:52:19 joerg Exp $
+
+--- src/ICMPTimeExceeded.cc.orig       2020-03-27 18:19:43.621887469 +0000
++++ src/ICMPTimeExceeded.cc
+@@ -78,14 +78,14 @@ ICMPTimeExceeded::getHeaderLength () {
+  */
+ void
+ ICMPTimeExceeded::dump () {
+-  log(DUMP, "ICMP Time Exceeded Header :\n");
+-  log(DUMP, "type                = %s\n", getTypeDesc());
+-  log(DUMP, "code                = %s\n", getCodeDesc());
+-  log(DUMP, "checksum            = %d\n", getChecksum());
+-  log(DUMP, "bytes 4-7           = 0x%x\n", *(uint32*)(header+4));
+-  log(DUMP, "Erroneous IP4 header :\n");
++  mylog(DUMP, "ICMP Time Exceeded Header :\n");
++  mylog(DUMP, "type                = %s\n", getTypeDesc());
++  mylog(DUMP, "code                = %s\n", getCodeDesc());
++  mylog(DUMP, "checksum            = %d\n", getChecksum());
++  mylog(DUMP, "bytes 4-7           = 0x%x\n", *(uint32*)(header+4));
++  mylog(DUMP, "Erroneous IP4 header :\n");
+   ip4_err->dump();
+-  log(DUMP, "Erroneous data :\n");
++  mylog(DUMP, "Erroneous data :\n");
+   dumpRawData(DUMP, data_err, 8);
+ }
+ 
Index: pkgsrc/net/paris-traceroute/patches/patch-src_IP4Header.cc
diff -u /dev/null pkgsrc/net/paris-traceroute/patches/patch-src_IP4Header.cc:1.1
--- /dev/null   Fri Mar 27 20:52:20 2020
+++ pkgsrc/net/paris-traceroute/patches/patch-src_IP4Header.cc  Fri Mar 27 20:52:19 2020
@@ -0,0 +1,37 @@
+$NetBSD: patch-src_IP4Header.cc,v 1.1 2020/03/27 20:52:19 joerg Exp $
+
+--- src/IP4Header.cc.orig      2020-03-27 18:19:46.190381099 +0000
++++ src/IP4Header.cc
+@@ -343,16 +343,16 @@ IP4Header::packPseudo (uint16 dgram_len,
+  */
+ void
+ IP4Header::dump () {
+-  log(DUMP, "IP4 header :");
+-  log(DUMP, "tos                = %d", getToS());
+-  log(DUMP, "total_length       = %d", getTotalLength());
+-  log(DUMP, "ttl                = %d", getTTL());
+-  log(DUMP, "protocol           = %d", getProtocol());
++  mylog(DUMP, "IP4 header :");
++  mylog(DUMP, "tos                = %d", getToS());
++  mylog(DUMP, "total_length       = %d", getTotalLength());
++  mylog(DUMP, "ttl                = %d", getTTL());
++  mylog(DUMP, "protocol           = %d", getProtocol());
+   struct in_addr addr;
+   addr.s_addr = *(uint32*)(header + 12);
+-  log(DUMP, "source_address     = %s", inet_ntoa(addr));
++  mylog(DUMP, "source_address     = %s", inet_ntoa(addr));
+   addr.s_addr = *(uint32*)(header + 16);
+-  log(DUMP, "dest_address       = %s", inet_ntoa(addr));
++  mylog(DUMP, "dest_address       = %s", inet_ntoa(addr));
+ }
+ 
+ /**
+@@ -360,7 +360,7 @@ IP4Header::dump () {
+  */
+ void
+ IP4Header::dumpRaw () {
+-  log(DUMP, "IP4 header :");
++  mylog(DUMP, "IP4 header :");
+   dumpRawData(WARN, header, header_len);
+ }
+ 
Index: pkgsrc/net/paris-traceroute/patches/patch-src_IP4Header__NetBSD.cc
diff -u /dev/null pkgsrc/net/paris-traceroute/patches/patch-src_IP4Header__NetBSD.cc:1.1
--- /dev/null   Fri Mar 27 20:52:20 2020
+++ pkgsrc/net/paris-traceroute/patches/patch-src_IP4Header__NetBSD.cc  Fri Mar 27 20:52:19 2020
@@ -0,0 +1,37 @@
+$NetBSD: patch-src_IP4Header__NetBSD.cc,v 1.1 2020/03/27 20:52:19 joerg Exp $
+
+--- src/IP4Header_NetBSD.cc.orig       2020-03-27 18:19:48.498481742 +0000
++++ src/IP4Header_NetBSD.cc
+@@ -272,16 +272,16 @@ IP4Header::packPseudo (uint16 dgram_len,
+  */
+ void
+ IP4Header::dump () {
+-  log(DUMP, "IP4 header :");
+-  log(DUMP, "tos                = %d", getToS());
+-  log(DUMP, "total_length       = %d", getTotalLength());
+-  log(DUMP, "ttl                = %d", getTTL());
+-  log(DUMP, "protocol           = %d", getProtocol());
++  mylog(DUMP, "IP4 header :");
++  mylog(DUMP, "tos                = %d", getToS());
++  mylog(DUMP, "total_length       = %d", getTotalLength());
++  mylog(DUMP, "ttl                = %d", getTTL());
++  mylog(DUMP, "protocol           = %d", getProtocol());
+   struct in_addr addr;
+   addr.s_addr = *(uint32*)(header + 12);
+-  log(DUMP, "source_address     = %s", inet_ntoa(addr));
++  mylog(DUMP, "source_address     = %s", inet_ntoa(addr));
+   addr.s_addr = *(uint32*)(header + 16);
+-  log(DUMP, "dest_address       = %s", inet_ntoa(addr));
++  mylog(DUMP, "dest_address       = %s", inet_ntoa(addr));
+ }
+ 
+ /**
+@@ -289,7 +289,7 @@ IP4Header::dump () {
+  */
+ void
+ IP4Header::dumpRaw () {
+-  log(DUMP, "IP4 header :");
++  mylog(DUMP, "IP4 header :");
+   dumpRawData(DUMP, header, header_len);
+ }
+ 
Index: pkgsrc/net/paris-traceroute/patches/patch-src_MPLSHeader.cc
diff -u /dev/null pkgsrc/net/paris-traceroute/patches/patch-src_MPLSHeader.cc:1.1
--- /dev/null   Fri Mar 27 20:52:20 2020
+++ pkgsrc/net/paris-traceroute/patches/patch-src_MPLSHeader.cc Fri Mar 27 20:52:19 2020
@@ -0,0 +1,49 @@
+$NetBSD: patch-src_MPLSHeader.cc,v 1.1 2020/03/27 20:52:19 joerg Exp $
+
+--- src/MPLSHeader.cc.orig     2020-03-27 18:19:50.848849889 +0000
++++ src/MPLSHeader.cc
+@@ -14,7 +14,7 @@ MPLSHeader::MPLSHeader(const uint8* data
+   int nbr_entries;
+   uint32 label;
+ 
+-  log(INFO, "MPLSHeader %d %d", length, offset);
++  mylog(INFO, "MPLSHeader %d %d", length, offset);
+   
+   header = new uint8[length];
+   header_len = length;
+@@ -26,7 +26,7 @@ MPLSHeader::MPLSHeader(const uint8* data
+ 
+   if (header[0]>>4 != 2) {
+     nbrLabels = 0;
+-    log(WARN, "MPLS version %d", header[0]>>4);
++    mylog(WARN, "MPLS version %d", header[0]>>4);
+   } else {
+     i = 4;
+ 
+@@ -61,7 +61,7 @@ MPLSHeader::MPLSHeader(const uint8* data
+     }
+   }
+   
+-  log(INFO, "MPLSHeader fin");
++  mylog(INFO, "MPLSHeader fin");
+ }
+ 
+ MPLSHeader::~MPLSHeader () {
+@@ -170,7 +170,7 @@ MPLSHeader::pack (uint8* data, int lengt
+  */
+ void
+ MPLSHeader::dump () {
+-  log(DUMP, "MPLS Header");
++  mylog(DUMP, "MPLS Header");
+   // xxx
+ }
+ 
+@@ -179,7 +179,7 @@ MPLSHeader::dump () {
+  */
+ void
+ MPLSHeader::dumpRaw () {
+-  log(DUMP, "MPLS Header :\n");
++  mylog(DUMP, "MPLS Header :\n");
+   dumpRawData(DUMP, header, header_len);
+   // xxx
+ }
Index: pkgsrc/net/paris-traceroute/patches/patch-src_MihScannerTracert.cc
diff -u /dev/null pkgsrc/net/paris-traceroute/patches/patch-src_MihScannerTracert.cc:1.1
--- /dev/null   Fri Mar 27 20:52:20 2020
+++ pkgsrc/net/paris-traceroute/patches/patch-src_MihScannerTracert.cc  Fri Mar 27 20:52:19 2020
@@ -0,0 +1,21 @@
+$NetBSD: patch-src_MihScannerTracert.cc,v 1.1 2020/03/27 20:52:19 joerg Exp $
+
+--- src/MihScannerTracert.cc.orig      2020-03-27 18:19:54.666910839 +0000
++++ src/MihScannerTracert.cc
+@@ -83,7 +83,7 @@ MihScannerTracert::trace () {
+     missing = (nbr_replies_received == 0) ? (missing + 1) : 0;
+ 
+     if (missing > opts->max_missing) {
+-      log(INFO, "Too many down hops -> stop algo");
++      mylog(INFO, "Too many down hops -> stop algo");
+       //pthread_mutex_unlock(&lock);
+       stop_algo = true;
+     }
+@@ -147,6 +147,6 @@ MihScannerTracert::trace () {
+ 
+ uint8
+ MihScannerTracert::getNbrReplies(uint8 ttl) {
+-  log(WARN, "TODO");
++  mylog(WARN, "TODO");
+   return 0;
+ }
Index: pkgsrc/net/paris-traceroute/patches/patch-src_NULLTracert.cc
diff -u /dev/null pkgsrc/net/paris-traceroute/patches/patch-src_NULLTracert.cc:1.1
--- /dev/null   Fri Mar 27 20:52:20 2020
+++ pkgsrc/net/paris-traceroute/patches/patch-src_NULLTracert.cc        Fri Mar 27 20:52:19 2020
@@ -0,0 +1,13 @@
+$NetBSD: patch-src_NULLTracert.cc,v 1.1 2020/03/27 20:52:19 joerg Exp $
+
+--- src/NULLTracert.cc.orig    2020-03-27 18:19:57.000133342 +0000
++++ src/NULLTracert.cc
+@@ -7,7 +7,7 @@
+ 
+ NULLTracert::NULLTracert () {
+       printf("tracert impl\n");       
+-  log(INFO, "NULL algo");
++  mylog(INFO, "NULL algo");
+ }
+ 
+ /**
Index: pkgsrc/net/paris-traceroute/patches/patch-src_Options.cc
diff -u /dev/null pkgsrc/net/paris-traceroute/patches/patch-src_Options.cc:1.1
--- /dev/null   Fri Mar 27 20:52:20 2020
+++ pkgsrc/net/paris-traceroute/patches/patch-src_Options.cc    Fri Mar 27 20:52:19 2020
@@ -0,0 +1,158 @@
+$NetBSD: patch-src_Options.cc,v 1.1 2020/03/27 20:52:19 joerg Exp $
+
+--- src/Options.cc.orig        2020-03-27 18:19:59.385262004 +0000
++++ src/Options.cc
+@@ -95,26 +95,26 @@ Options::Options (int argc, char** argv)
+                               set_log_level(ERROR);
+         break;
+       case 'h':   // help
+-        log(DUMP, "Option : help");
++        mylog(DUMP, "Option : help");
+         help();
+         break;
+       case 'V':   // version
+-        log(DUMP, "Option : version");
++        mylog(DUMP, "Option : version");
+         version();
+         break;
+       case 'f':   // first ttl
+-        log(DUMP, "Option : first ttl, param = %s", optarg);
++        mylog(DUMP, "Option : first ttl, param = %s", optarg);
+         ttl_initial = atoi(optarg);
+         break;
+       case 'F':
+               strncpy(targets, optarg, 32);
+               break;
+       case 'm':   // max ttl
+-        log(DUMP, "Option : max ttl, param = %s", optarg);
++        mylog(DUMP, "Option : max ttl, param = %s", optarg);
+         ttl_max = atoi(optarg);
+         break;
+       case 'p':   // protocol
+-        log(DUMP, "Option : protocol, param = %s", optarg);
++        mylog(DUMP, "Option : protocol, param = %s", optarg);
+         strncpy(protocol, optarg, 5);
+         
+         if (strncmp(optarg, "icmp", 4) == 0) {
+@@ -130,7 +130,7 @@ Options::Options (int argc, char** argv)
+               bandwidth = atoi(optarg);
+               break;
+       case 's':   // source port
+-        log(DUMP, "Option : source_port, param = %s", optarg);
++        mylog(DUMP, "Option : source_port, param = %s", optarg);
+         if (strncmp(optarg, "pid", 3) == 0) {
+               // XXX at least we don't want to interfer with classic traceroute
+                               proc_id = getpid() + 32768;
+@@ -141,55 +141,55 @@ Options::Options (int argc, char** argv)
+                               }
+         break;
+       case 'd':   // destination port
+-        log(DUMP, "Option : dest_port, param = %s", optarg);
++        mylog(DUMP, "Option : dest_port, param = %s", optarg);
+         dst_port = atoi(optarg);
+         break;
+       case 't':   // tos
+-        log(DUMP, "Option : tos, param = %s", optarg);
++        mylog(DUMP, "Option : tos, param = %s", optarg);
+         tos = atoi(optarg);
+         break;
+       case 'w':   // wait between probes
+-        log(DUMP, "Option : w, param = %s", optarg);
++        mylog(DUMP, "Option : w, param = %s", optarg);
+         delay_between_probes = atoi(optarg);
+         break;
+       case 'T':   // timeout for each probe
+-        log(DUMP, "Option : timeout, param = %s", optarg);
++        mylog(DUMP, "Option : timeout, param = %s", optarg);
+         timeout = atoi(optarg);
+         break;
+       case 'q':   // Number of tests before we consider a router down
+-        log(DUMP, "Option : retry, param = %s", optarg);
++        mylog(DUMP, "Option : retry, param = %s", optarg);
+         max_try = atoi(optarg);
+         break;
+       case 'r':
+               return_flow_id = atoi(optarg);
+               break;
+       case 'M':   // Number of missing hop before stopping the traceroute
+-        log(DUMP, "Option : missing_hop, param = %s", optarg);
++        mylog(DUMP, "Option : missing_hop, param = %s", optarg);
+         max_missing = atoi(optarg);
+         break;
+       case 'a':
+-        log(DUMP, "Option : algorithm, param = %s", optarg);
++        mylog(DUMP, "Option : algorithm, param = %s", optarg);
+         strncpy(algo, optarg, 20);
+         if (strncmp(algo, "help", 20) == 0) helpAlgo();
+         break;
+       case 'L':
+-        log(DUMP, "Options : probe length, param = %s", optarg);
++        mylog(DUMP, "Options : probe length, param = %s", optarg);
+         probe_length = atoi(optarg);
+         break;
+       case 'n':   // Print hop addresses numerically
+-        log(DUMP, "Option : numeric = true");
++        mylog(DUMP, "Option : numeric = true");
+         resolve_hostname = false;
+         break;
+       case 'i':   // Print the IP Id of the returned packet
+-        log(DUMP, "Option : ipid = true");
++        mylog(DUMP, "Option : ipid = true");
+         display_ipid = true;
+         break;
+       case 'l':   // Print the TTL of the returned packet
+-        log(DUMP, "Option : print_ttl = true");
++        mylog(DUMP, "Option : print_ttl = true");
+         display_ttl = true;
+         break;
+       case 'b':
+-        log(DUMP, "Option : id_initial, param = %s", optarg);
++        mylog(DUMP, "Option : id_initial, param = %s", optarg);
+         id_initial = atoi(optarg);
+         break;
+       case 'Z':
+@@ -219,7 +219,7 @@ Options::Options (int argc, char** argv)
+ 
+       if (targets[0] == 0x00)
+       {
+-        log(DUMP, "dst_addr = %s", argv[optind]);
++        mylog(DUMP, "dst_addr = %s", argv[optind]);
+         if (argv[optind] == NULL) {
+           help();
+           exit(1);
+@@ -337,20 +337,20 @@ Options::version () {
+ 
+ void
+ Options::dump () {
+-  log(DUMP, "protocol     = %s", protocol);
+-  log(DUMP, "src_add      = %s", src_addr);
+-  log(DUMP, "dst_addr     = %s", dst_addr);
+-  log(DUMP, "ttl_initial  = %d", ttl_initial);
+-  log(DUMP, "ttl_max      = %d", ttl_max);
+-  log(DUMP, "tos          = %d", tos);
+-  log(DUMP, "probe_length = %d", probe_length);
+-  log(DUMP, "algo         = %s", algo);
+-  log(DUMP, "timeout      = %d", timeout);
+-  log(DUMP, "delay        = %d", delay_between_probes);
+-  log(DUMP, "max_try      = %d", max_try);
+-  log(DUMP, "max_missing  = %d", max_missing);
+-  log(DUMP, "id_initial   = %d", id_initial);
+-  log(DUMP, "resolve      = %s", resolve_hostname ? "true" : "false");
+-  log(DUMP, "ipid         = %s", display_ipid ? "true" : "false");
++  mylog(DUMP, "protocol     = %s", protocol);
++  mylog(DUMP, "src_add      = %s", src_addr);
++  mylog(DUMP, "dst_addr     = %s", dst_addr);
++  mylog(DUMP, "ttl_initial  = %d", ttl_initial);
++  mylog(DUMP, "ttl_max      = %d", ttl_max);
++  mylog(DUMP, "tos          = %d", tos);
++  mylog(DUMP, "probe_length = %d", probe_length);
++  mylog(DUMP, "algo         = %s", algo);
++  mylog(DUMP, "timeout      = %d", timeout);
++  mylog(DUMP, "delay        = %d", delay_between_probes);
++  mylog(DUMP, "max_try      = %d", max_try);
++  mylog(DUMP, "max_missing  = %d", max_missing);
++  mylog(DUMP, "id_initial   = %d", id_initial);
++  mylog(DUMP, "resolve      = %s", resolve_hostname ? "true" : "false");
++  mylog(DUMP, "ipid         = %s", display_ipid ? "true" : "false");
+ }
+ 
Index: pkgsrc/net/paris-traceroute/patches/patch-src_PackByPackTracert.cc
diff -u /dev/null pkgsrc/net/paris-traceroute/patches/patch-src_PackByPackTracert.cc:1.1
--- /dev/null   Fri Mar 27 20:52:20 2020
+++ pkgsrc/net/paris-traceroute/patches/patch-src_PackByPackTracert.cc  Fri Mar 27 20:52:19 2020
@@ -0,0 +1,30 @@
+$NetBSD: patch-src_PackByPackTracert.cc,v 1.1 2020/03/27 20:52:19 joerg Exp $
+
+--- src/PackByPackTracert.cc.orig      2020-03-27 18:20:01.586393366 +0000
++++ src/PackByPackTracert.cc
+@@ -16,7 +16,7 @@
+ 
+ PackByPackTracert::PackByPackTracert (Options* opts) : TracertImpl(opts){
+   // Initialisation
+-  log(INFO, "PackByPack algo");
++  mylog(INFO, "PackByPack algo");
+ }
+ 
+ PackByPackTracert::~PackByPackTracert () {
+@@ -94,7 +94,7 @@ PackByPackTracert::trace (char* target, 
+       missing = 0;
+     
+     if (missing > opts->max_missing) {
+-      log(INFO, "Too many down hops -> stop algo");
++      mylog(INFO, "Too many down hops -> stop algo");
+       //pthread_mutex_unlock(&lock);
+       stop_algo = true;
+     }
+@@ -116,6 +116,6 @@ PackByPackTracert::trace (char* target, 
+ 
+ uint8
+ PackByPackTracert::getNbrReplies(uint8 ttl) {
+-  log(WARN, "TODO");
++  mylog(WARN, "TODO");
+   return 0;
+ }
Index: pkgsrc/net/paris-traceroute/patches/patch-src_Reply.cc
diff -u /dev/null pkgsrc/net/paris-traceroute/patches/patch-src_Reply.cc:1.1
--- /dev/null   Fri Mar 27 20:52:20 2020
+++ pkgsrc/net/paris-traceroute/patches/patch-src_Reply.cc      Fri Mar 27 20:52:19 2020
@@ -0,0 +1,18 @@
+$NetBSD: patch-src_Reply.cc,v 1.1 2020/03/27 20:52:19 joerg Exp $
+
+--- src/Reply.cc.orig  2020-03-27 18:20:05.312213338 +0000
++++ src/Reply.cc
+@@ -20,11 +20,11 @@ Reply::replyFactory (const uint8* packet
+       case 6:  // TCP
+         return new TCPReply(packet, packet_len);
+       default:
+-        log(DUMP, "The reply used protocol %d", protocol);
++        mylog(DUMP, "The reply used protocol %d", protocol);
+         return NULL;
+     }
+   } else {
+-    log(DUMP, "Malformed reply");
++    mylog(DUMP, "Malformed reply");
+     return NULL;
+   }
+ }
Index: pkgsrc/net/paris-traceroute/patches/patch-src_ScoutTracert.cc
diff -u /dev/null pkgsrc/net/paris-traceroute/patches/patch-src_ScoutTracert.cc:1.1
--- /dev/null   Fri Mar 27 20:52:20 2020
+++ pkgsrc/net/paris-traceroute/patches/patch-src_ScoutTracert.cc       Fri Mar 27 20:52:19 2020
@@ -0,0 +1,12 @@
+$NetBSD: patch-src_ScoutTracert.cc,v 1.1 2020/03/27 20:52:19 joerg Exp $
+
+--- src/ScoutTracert.cc.orig   2020-03-27 18:20:08.083937225 +0000
++++ src/ScoutTracert.cc
+@@ -68,6 +68,6 @@ ScoutTracert::trace (char* target, int i
+ 
+ uint8
+ ScoutTracert::getNbrReplies(uint8 ttl) {
+-  log(WARN, "TODO");
++  mylog(WARN, "TODO");
+   return 0;
+ }
Index: pkgsrc/net/paris-traceroute/patches/patch-src_Server.cc
diff -u /dev/null pkgsrc/net/paris-traceroute/patches/patch-src_Server.cc:1.1
--- /dev/null   Fri Mar 27 20:52:20 2020
+++ pkgsrc/net/paris-traceroute/patches/patch-src_Server.cc     Fri Mar 27 20:52:19 2020
@@ -0,0 +1,83 @@
+$NetBSD: patch-src_Server.cc,v 1.1 2020/03/27 20:52:19 joerg Exp $
+
+--- src/Server.cc.orig 2007-06-07 12:32:28.000000000 +0000
++++ src/Server.cc
+@@ -115,19 +115,19 @@ Server::Server (Options* opts, const cha
+  * Stop the server.
+  */
+ Server::~Server () {
+-  log(INFO, "delete server");
++  mylog(INFO, "delete server");
+   stopThread();
+-  log(INFO, "stop thread done");
++  mylog(INFO, "stop thread done");
+   //close(sock_server);
+-  log(INFO, "close socket done");
++  mylog(INFO, "close socket done");
+ // STRANGE: uder linux, the recvfrom wont unblock when we  
+ // close the socket if there is no timeour on the socket. 
+ #if 0  
+   pthread_join(thread, NULL);
+-  log(INFO, "join done");
++  mylog(INFO, "join done");
+ #endif  
+   pthread_mutex_destroy(&lock);
+-  log(INFO, "destroy mutex done");
++  mylog(INFO, "destroy mutex done");
+ }
+ 
+ /**
+@@ -191,7 +191,7 @@ Server::runThread () {
+   int packet_count = 0;
+   fd_set sfd;
+   
+-  log(INFO, "waiting for the first packet..\n");
++  mylog(INFO, "waiting for the first packet..\n");
+   while (1) {
+       
+       pthread_mutex_lock(&lock);      
+@@ -209,12 +209,12 @@ Server::runThread () {
+ 
+               if (ret < 0)
+               {
+-                      log(WARN, "select failed\n");
++                      mylog(WARN, "select failed\n");
+                       exit(1);
+               }
+               else if (ret == 0)
+               {
+-                      log(WARN, "select timeout\n");
++                      mylog(WARN, "select timeout\n");
+                       continue;
+               }
+ 
+@@ -251,16 +251,16 @@ Server::runThread () {
+ 
+               if (data_len > 0) {
+                       if (packet_count == 0)
+-                              log(INFO, "Captured first packet!\n");
++                              mylog(INFO, "Captured first packet!\n");
+                       
+                       packet_count++;
+                       
+-                      log(DUMP, "Incoming message :");
+-                log(DUMP, "parsing.. %x %d", data, data_len);
++                      mylog(DUMP, "Incoming message :");
++                mylog(DUMP, "parsing.. %p %d", data, data_len);
+                 dumpRawData(DUMP, data, data_len);
+                       
+                       Reply* reply = Reply::replyFactory(data, data_len);
+-                      log(DUMP, "Incoming message parsed :");
++                      mylog(DUMP, "Incoming message parsed :");
+                       reply->dump();
+                       //printf("server locking...\n");
+                       pthread_mutex_lock(&lock);
+@@ -297,7 +297,7 @@ Server::runThread () {
+                       //printf("client id = %d\n", id);
+                       
+                       if (id < 0 || id >= 32)
+-                              log(FATAL, "bug, id can't be greater than 31");
++                              mylog(FATAL, "bug, id can't be greater than 31");
+                       reply->proc_id = opts->proc_id;
+                       
+                       //if (opts->debug)
Index: pkgsrc/net/paris-traceroute/patches/patch-src_TCPHeader.cc
diff -u /dev/null pkgsrc/net/paris-traceroute/patches/patch-src_TCPHeader.cc:1.1
--- /dev/null   Fri Mar 27 20:52:20 2020
+++ pkgsrc/net/paris-traceroute/patches/patch-src_TCPHeader.cc  Fri Mar 27 20:52:19 2020
@@ -0,0 +1,50 @@
+$NetBSD: patch-src_TCPHeader.cc,v 1.1 2020/03/27 20:52:19 joerg Exp $
+
+--- src/TCPHeader.cc.orig      2020-03-27 18:20:13.353228023 +0000
++++ src/TCPHeader.cc
+@@ -287,21 +287,21 @@ TCPHeader::pack (uint8* data, int length
+  */
+ void
+ TCPHeader::dump () {
+-  log(DUMP, "TCP header :");
+-  log(DUMP, "source_port        = %d", getSourcePort());
+-  log(DUMP, "dest_port          = %d", getDestPort());
+-  log(DUMP, "sequence_number    = %d", getSeqNumber());
+-  log(DUMP, "ack_number         = %d", getAckNumber());
+-  log(DUMP, "flags              = 0x%x", header[13]);
+-  log(DUMP, "fin_flag(1)        = %s", getFINFlag() ? "true" : "false");
+-  log(DUMP, "syn_flag(2)        = %s", getSYNFlag() ? "true" : "false");
+-  log(DUMP, "rst_flag(4)        = %s", getRSTFlag() ? "true" : "false");
+-  log(DUMP, "psh_flag(8)        = %s", getPSHFlag() ? "true" : "false");
+-  log(DUMP, "ack_flag(16)       = %s", getACKFlag() ? "true" : "false");
+-  log(DUMP, "urg_flag(32)       = %s", getURGFlag() ? "true" : "false");
+-  log(DUMP, "windown            = %d", getWindow());
+-  log(DUMP, "checksum           = %d", getChecksum());
+-  log(DUMP, "urgent_pointer     = %d", getUrgentPointer());
++  mylog(DUMP, "TCP header :");
++  mylog(DUMP, "source_port        = %d", getSourcePort());
++  mylog(DUMP, "dest_port          = %d", getDestPort());
++  mylog(DUMP, "sequence_number    = %d", getSeqNumber());
++  mylog(DUMP, "ack_number         = %d", getAckNumber());
++  mylog(DUMP, "flags              = 0x%x", header[13]);
++  mylog(DUMP, "fin_flag(1)        = %s", getFINFlag() ? "true" : "false");
++  mylog(DUMP, "syn_flag(2)        = %s", getSYNFlag() ? "true" : "false");
++  mylog(DUMP, "rst_flag(4)        = %s", getRSTFlag() ? "true" : "false");
++  mylog(DUMP, "psh_flag(8)        = %s", getPSHFlag() ? "true" : "false");
++  mylog(DUMP, "ack_flag(16)       = %s", getACKFlag() ? "true" : "false");
++  mylog(DUMP, "urg_flag(32)       = %s", getURGFlag() ? "true" : "false");
++  mylog(DUMP, "windown            = %d", getWindow());
++  mylog(DUMP, "checksum           = %d", getChecksum());
++  mylog(DUMP, "urgent_pointer     = %d", getUrgentPointer());
+ }
+ 
+ /**
+@@ -309,7 +309,7 @@ TCPHeader::dump () {
+  */
+ void
+ TCPHeader::dumpRaw () {
+-  log(DUMP, "TCP header :");
++  mylog(DUMP, "TCP header :");
+   dumpRawData(DUMP, header, header_len);
+ }
+ 
Index: pkgsrc/net/paris-traceroute/patches/patch-src_TCPProbe.cc
diff -u /dev/null pkgsrc/net/paris-traceroute/patches/patch-src_TCPProbe.cc:1.1
--- /dev/null   Fri Mar 27 20:52:20 2020
+++ pkgsrc/net/paris-traceroute/patches/patch-src_TCPProbe.cc   Fri Mar 27 20:52:19 2020
@@ -0,0 +1,26 @@
+$NetBSD: patch-src_TCPProbe.cc,v 1.1 2020/03/27 20:52:19 joerg Exp $
+
+--- src/TCPProbe.cc.orig       2020-03-27 18:20:16.329393883 +0000
++++ src/TCPProbe.cc
+@@ -132,10 +132,10 @@ TCPProbe::getID () {
+ 
+ void
+ TCPProbe::dump () {
+-  log(DUMP, "==> TCP Probe :");
++  mylog(DUMP, "==> TCP Probe :");
+   for (int i = 0; i  < getNbrHeaders(); i++)
+     getHeader(i)->dump();
+-  log(DUMP, "Data :");
++  mylog(DUMP, "Data :");
+   if (data != NULL)
+     dumpRawData(DUMP, data, data_length);
+ }
+@@ -145,7 +145,7 @@ TCPProbe::dumpRaw () {
+   uint8* data;
+   int   length;
+   getDatagram(&data, &length);
+-  log(DUMP, "==> TCP Probe :");
++  mylog(DUMP, "==> TCP Probe :");
+   dumpRawData(DUMP, data, length);
+ }
+ 
Index: pkgsrc/net/paris-traceroute/patches/patch-src_TCPReply.cc
diff -u /dev/null pkgsrc/net/paris-traceroute/patches/patch-src_TCPReply.cc:1.1
--- /dev/null   Fri Mar 27 20:52:20 2020
+++ pkgsrc/net/paris-traceroute/patches/patch-src_TCPReply.cc   Fri Mar 27 20:52:19 2020
@@ -0,0 +1,44 @@
+$NetBSD: patch-src_TCPReply.cc,v 1.1 2020/03/27 20:52:19 joerg Exp $
+
+--- src/TCPReply.cc.orig       2020-03-27 18:20:19.472483045 +0000
++++ src/TCPReply.cc
+@@ -33,7 +33,7 @@ TCPReply::getType () {
+ int TCPReply::getProcId () {
+   // Get the TCP header
+   TCPHeader* tcp = (TCPHeader*)getHeader(1);
+-  //log(WARN, "TCPReply::getProcId TODO %x", tcp->getAckNumber() - 1);
++  //mylog(WARN, "TCPReply::getProcId TODO %x", tcp->getAckNumber() - 1);
+   // Return (ack number - 1)
+   return (tcp->getAckNumber() - 1) >> 16;
+ }
+@@ -42,26 +42,26 @@ int
+ TCPReply::getID () {
+   // Get the TCP header
+   TCPHeader* tcp = (TCPHeader*)getHeader(1);
+-  //log(WARN, "TCPReply::getId TODO");
++  //mylog(WARN, "TCPReply::getId TODO");
+   // Return (ack number - 1)
+   return (tcp->getAckNumber() - 1) & 0xffff;
+ }
+ 
+ int
+ TCPReply::getID2 () {
+-      log(WARN, "TCPReply::getID2 TODO");
++      mylog(WARN, "TCPReply::getID2 TODO");
+       return 0;
+ }
+ 
+ int
+ TCPReply::getID3 () {
+-      log(WARN, "TCPReply::getID3 TODO");
++      mylog(WARN, "TCPReply::getID3 TODO");
+       return 0;
+ }
+ 
+ int
+ TCPReply::getReturnFlowId () {
+-      //log(WARN, "getReturnFlowId() TODO\n");
++      //mylog(WARN, "getReturnFlowId() TODO\n");
+       return 0;
+ }
+ 
Index: pkgsrc/net/paris-traceroute/patches/patch-src_TracertImpl.cc
diff -u /dev/null pkgsrc/net/paris-traceroute/patches/patch-src_TracertImpl.cc:1.1
--- /dev/null   Fri Mar 27 20:52:20 2020
+++ pkgsrc/net/paris-traceroute/patches/patch-src_TracertImpl.cc        Fri Mar 27 20:52:19 2020
@@ -0,0 +1,185 @@
+$NetBSD: patch-src_TracertImpl.cc,v 1.1 2020/03/27 20:52:19 joerg Exp $
+
+--- src/TracertImpl.cc.orig    2007-05-31 15:34:28.000000000 +0000
++++ src/TracertImpl.cc
+@@ -5,6 +5,7 @@
+ #include "Reply.h"
+ #include "Time.h"
+ 
++#include <stdint.h>
+ #include <string.h>
+ #include <sys/types.h>
+ #include <sys/socket.h>
+@@ -26,7 +27,7 @@ TracertImpl::TracertImpl () {
+ TracertImpl::TracertImpl (Options* opts) {
+   //printf("tracert impl 1\n");       
+   //if (opts->debug)
+-  //  log(WARN, "TracertImpl::TracertImpl(opts)");
++  //  mylog(WARN, "TracertImpl::TracertImpl(opts)");
+   
+   // Initialisation
+   this->opts = opts;
+@@ -45,7 +46,7 @@ TracertImpl::TracertImpl (Options* opts)
+   
+   ttl_current = opts->ttl_initial;
+   
+-  log(INFO, "HopByHop algo");
++  mylog(INFO, "HopByHop algo");
+ }
+ 
+ /**
+@@ -180,7 +181,7 @@ TracertImpl::sendProbe3 (int id, int xtu
+   probes_by_id[probe->getID()] = tprobe;
+ 
+   // ... and send it
+-  log(INFO, "Send probe, ttl=%d, id=%x", ttl_current, probe->getID());
++  mylog(INFO, "Send probe, ttl=%d, id=%x", ttl_current, probe->getID());
+   tprobe->probe->dump();
+   tprobe->send_time    = time->getCurrentTime();
+   tprobe->timeout_time = tprobe->send_time + (opts->timeout * 1000);
+@@ -212,7 +213,7 @@ TracertImpl::reSendProbe(TimedProbe * tp
+ void
+ TracertImpl::waitProbes () {
+   //if (opts->debug)
+-  //log(WARN, "TracertImpl::waitProbes sent=%d recv=%d", nbr_probes_sent, nbr_replies_received);
++  //mylog(WARN, "TracertImpl::waitProbes sent=%d recv=%d", nbr_probes_sent, nbr_replies_received);
+ 
+   // Wait all replies for this TTL
+   struct timeval  now;
+@@ -227,7 +228,7 @@ TracertImpl::waitProbes () {
+     
+     if (res == ETIMEDOUT) {
+       // Timeout
+-      log(DUMP, "Timeout");
++      mylog(DUMP, "Timeout");
+     }
+   }
+ }
+@@ -251,12 +252,12 @@ TracertImpl::validateReply(Reply *reply,
+     
+     host_addr.s_addr         = reply->getSourceAddress();
+     
+-    log(WARN, "IP Options in this reply, from %s !", inet_ntoa(host_addr));
++    mylog(WARN, "IP Options in this reply, from %s !", inet_ntoa(host_addr));
+     reply->dumpRaw();
+   }
+ 
+   if (reply->getOriginalProtocol() != opts->protocole) {
+-    log(DUMP, "Bad protocol %d %d", opts->protocole, reply->getOriginalProtocol());
++    mylog(DUMP, "Bad protocol %d %d", opts->protocole, reply->getOriginalProtocol());
+     
+     //reply->dumpRaw();
+     
+@@ -265,7 +266,7 @@ TracertImpl::validateReply(Reply *reply,
+ 
+       if (reply->getProcId() != opts->proc_id) {
+   //if (reply->getProcId() != opts->src_port) {
+-    log(DUMP, "Bad ProcId : %d %d", reply->getProcId(), opts->src_port);
++    mylog(DUMP, "Bad ProcId : %d %d", reply->getProcId(), opts->src_port);
+     
+     return NULL;
+   }
+@@ -321,14 +322,14 @@ TracertImpl::validateReply(Reply *reply,
+   
+   int ret_flow_id = reply->getReturnFlowId();
+   
+-  //log(WARN, "Return Flow id : 0x%x", ret_flow_id);
++  //mylog(WARN, "Return Flow id : 0x%x", ret_flow_id);
+   if (opts->return_flow_id != -1 && ret_flow_id != opts->return_flow_id) {
+-      log(WARN, "Bad return flow id 0x%x from %s", ret_flow_id, Util::my_inet_ntoa(reply->getSourceAddress()));
++      mylog(WARN, "Bad return flow id 0x%x from %s", ret_flow_id, Util::my_inet_ntoa(reply->getSourceAddress()));
+       
+       uint32 resw = reply->getReservedWords();
+       unsigned char *p = (unsigned char *)&resw;
+       
+-      log(WARN, "ICMP reserved words %x %d %d %d %d", resw, p[3], p[2], p[1], p[0]);
++      mylog(WARN, "ICMP reserved words %x %d %d %d %d", resw, p[3], p[2], p[1], p[0]);
+       
+       //reply->dumpRaw();
+       }
+@@ -337,7 +338,7 @@ TracertImpl::validateReply(Reply *reply,
+ 
+   // If this reply is not associated to a probe, don't handle it
+   if (tprobe == NULL) {
+-    log(DUMP, "Can't find the probe associated to this reply to target %s", target);
++    mylog(DUMP, "Can't find the probe associated to this reply to target %" PRIu32, target);
+     //printf("ID=0x%x, initial=0x%x\n", id, id_initial);
+     //reply->dumpRaw();
+     return NULL;
+@@ -345,7 +346,7 @@ TracertImpl::validateReply(Reply *reply,
+ 
+   // If the reply is a duplicate, don't handle it
+   if (tprobe->arrival_time != 0) {
+-    log(DUMP, "Duplicated reply received");
++    mylog(DUMP, "Duplicated reply received");
+     
+     return NULL;
+   }
+@@ -353,7 +354,7 @@ TracertImpl::validateReply(Reply *reply,
+   // If the reply has timed out, don't handle it
+   //long arrival_time = time->getCurrentTime();
+   if (arrival_time > tprobe->timeout_time) {
+-    log(DUMP, "A reply received which has timed out %d", arrival_time - tprobe->timeout_time);
++    mylog(DUMP, "A reply received which has timed out %d", arrival_time - tprobe->timeout_time);
+     return NULL;
+   }
+ 
+@@ -365,7 +366,7 @@ TracertImpl::validateReply(Reply *reply,
+         && reply->getOriginalDestAddress() != tprobe->destination_address)
+   {
+       char *dest = strdup(Util::my_inet_ntoa(tprobe->destination_address));
+-    log(WARN, "A reply received with bad original destination address %s, should be %s", Util::my_inet_ntoa(reply->getOriginalDestAddress()), dest);
++    mylog(WARN, "A reply received with bad original destination address %s, should be %s", Util::my_inet_ntoa(reply->getOriginalDestAddress()), dest);
+     delete dest;
+     
+     //return NULL;
+@@ -420,13 +421,13 @@ TracertImpl::wakeup(Reply* reply) {
+ 
+   // Check if a connection reset is required
+   if (reply->resetRequired()) {
+-    log(INFO, "Reset, id=%x", reply->getID());
++    mylog(INFO, "Reset, id=%x", reply->getID());
+     Probe* probe = Probe::probeFactory(opts->protocol,
+         opts->src_addr, opts->src_port,
+         target, opts->dst_port,
+         opts->ttl_max, opts->tos, 0, 0,
+         reply->getResetID(), opts->return_flow_id, true);
+-    log(DUMP, "Send message :");
++    mylog(DUMP, "Send message :");
+     probe->dump();
+     probe->send();
+   }
+@@ -449,7 +450,7 @@ TracertImpl::wakeup(Reply* reply) {
+   // Check if all replies for this ttl have been received
+   nbr_replies_received++;
+   if (all_probes_sent && nbr_probes_sent == nbr_replies_received) {
+-    log(INFO, "All probes have been acknowledged");
++    mylog(INFO, "All probes have been acknowledged");
+     pthread_cond_signal(&cond_wait);
+   }
+ }
+@@ -469,13 +470,13 @@ TracertImpl::notifyReply (Reply* reply, 
+   }
+ 
+   // The reply is OK, update the timed probe associated to it
+-  log(DUMP, "Valid reply, id=%x", reply->getID());
++  mylog(DUMP, "Valid reply, id=%x", reply->getID());
+       //printf(".\n");
+       //printf("update\n");
+   updateInfos(tprobe, reply);
+   //printf("update done\n");
+   if (reply->IPOptions())
+-    log(WARN, "IP Options in this reply, from %s !", tprobe->host_address);
++    mylog(WARN, "IP Options in this reply, from %s !", tprobe->host_address);
+   
+   //printf("wakeup\n");
+   wakeup(reply);
+@@ -504,7 +505,7 @@ TracertImpl::getNbrProbes(uint8 ttl) {
+ 
+ uint8
+ TracertImpl::getNbrReplies(uint8 ttl) {
+-  log(WARN, "TODO");
++  mylog(WARN, "TODO");
+   return 0;
+ }
+ 
Index: pkgsrc/net/paris-traceroute/patches/patch-src_UDPHeader.cc
diff -u /dev/null pkgsrc/net/paris-traceroute/patches/patch-src_UDPHeader.cc:1.1
--- /dev/null   Fri Mar 27 20:52:20 2020
+++ pkgsrc/net/paris-traceroute/patches/patch-src_UDPHeader.cc  Fri Mar 27 20:52:19 2020
@@ -0,0 +1,21 @@
+$NetBSD: patch-src_UDPHeader.cc,v 1.1 2020/03/27 20:52:19 joerg Exp $
+
+--- src/UDPHeader.cc.orig      2020-03-27 18:20:25.642276689 +0000
++++ src/UDPHeader.cc
+@@ -140,11 +140,11 @@ UDPHeader::pack (uint8* data, int length
+  */
+ void
+ UDPHeader::dump () {
+-  log(DUMP, "UDP header :");
+-  log(DUMP, "source_port        = %d", getSourcePort());
+-  log(DUMP, "dest_port          = %d", getDestPort());
+-  log(DUMP, "datagram_length    = %d", getDatagramLength());
+-  log(DUMP, "checksum           = %d", getChecksum());
++  mylog(DUMP, "UDP header :");
++  mylog(DUMP, "source_port        = %d", getSourcePort());
++  mylog(DUMP, "dest_port          = %d", getDestPort());
++  mylog(DUMP, "datagram_length    = %d", getDatagramLength());
++  mylog(DUMP, "checksum           = %d", getChecksum());
+ }
+ 
+ /**
Index: pkgsrc/net/paris-traceroute/patches/patch-src_UDPProbe.cc
diff -u /dev/null pkgsrc/net/paris-traceroute/patches/patch-src_UDPProbe.cc:1.1
--- /dev/null   Fri Mar 27 20:52:20 2020
+++ pkgsrc/net/paris-traceroute/patches/patch-src_UDPProbe.cc   Fri Mar 27 20:52:19 2020
@@ -0,0 +1,35 @@
+$NetBSD: patch-src_UDPProbe.cc,v 1.1 2020/03/27 20:52:19 joerg Exp $
+
+--- src/UDPProbe.cc.orig       2020-03-27 18:20:27.983407363 +0000
++++ src/UDPProbe.cc
+@@ -143,7 +143,7 @@ UDPProbe::UDPProbe (const char* src_addr
+   uint8* d = new uint8[data_len];
+   memset(d, 0, data_len);
+ #ifndef DEVANOMALIES
+-      //log(WARN, "desactivated ID in UDP DATA");
++      //mylog(WARN, "desactivated ID in UDP DATA");
+   memcpy(d, &id, 2);
+ #endif
+   setData(d, data_len);
+@@ -244,10 +244,10 @@ UDPProbe::getID () {
+  */
+ void
+ UDPProbe::dump () {
+-  log(DUMP, "==> UDP Probe :");
++  mylog(DUMP, "==> UDP Probe :");
+   for (int i = 0; i  < getNbrHeaders(); i++)
+     getHeader(i)->dump();
+-  log(DUMP, "Data :");
++  mylog(DUMP, "Data :");
+   if (data != NULL)
+     dumpRawData(DUMP, data, data_length);
+ }
+@@ -260,7 +260,7 @@ UDPProbe::dumpRaw () {
+   uint8* data;
+   int   length;
+   getDatagram(&data, &length);
+-  log(DUMP, "==> UDP Probe :");
++  mylog(DUMP, "==> UDP Probe :");
+   dumpRawData(DUMP, data, length);
+ }
+ 
Index: pkgsrc/net/paris-traceroute/patches/patch-src_Util__NetBSD.cc
diff -u /dev/null pkgsrc/net/paris-traceroute/patches/patch-src_Util__NetBSD.cc:1.1
--- /dev/null   Fri Mar 27 20:52:20 2020
+++ pkgsrc/net/paris-traceroute/patches/patch-src_Util__NetBSD.cc       Fri Mar 27 20:52:19 2020
@@ -0,0 +1,22 @@
+$NetBSD: patch-src_Util__NetBSD.cc,v 1.1 2020/03/27 20:52:19 joerg Exp $
+
+--- src/Util_NetBSD.cc.orig    2020-03-27 18:20:30.573271054 +0000
++++ src/Util_NetBSD.cc
+@@ -37,7 +37,7 @@ Util::getRoute (const char* dest) {
+   //#fscanf(fd, "%s", buff);
+   //pclose(fd);
+ 
+-  log(INFO, "Source address = %s\n", buff);
++  mylog(INFO, "Source address = %s\n", buff);
+ 
+   return strdup(buff);
+ }
+@@ -191,7 +191,7 @@ Util::write32 (uint8* data, int ofs, uin
+ int
+ Util::protocol2int (const char* protocol) {
+   struct protoent* proto = getprotobyname(protocol);
+-  log(DUMP, "p_proto = %d", proto->p_proto);
++  mylog(DUMP, "p_proto = %d", proto->p_proto);
+   return proto->p_proto;
+ }
+ 
Index: pkgsrc/net/paris-traceroute/patches/patch-src_common.h
diff -u /dev/null pkgsrc/net/paris-traceroute/patches/patch-src_common.h:1.1
--- /dev/null   Fri Mar 27 20:52:20 2020
+++ pkgsrc/net/paris-traceroute/patches/patch-src_common.h      Fri Mar 27 20:52:19 2020
@@ -0,0 +1,22 @@
+$NetBSD: patch-src_common.h,v 1.1 2020/03/27 20:52:19 joerg Exp $
+
+--- src/common.h.orig  2020-03-27 18:18:13.457796123 +0000
++++ src/common.h
+@@ -41,7 +41,7 @@ const char* lvl2str (int lvl);
+ #ifdef __GNUC__
+ void log_c (int lvl, const char* file, int line, const char* format, ...)
+               __attribute__ ((format (printf, 4, 5)));
+-#define log(lvl, args... ) \
++#define mylog(lvl, args... ) \
+       if (lvl <= get_log_level()) log_c(lvl, __FILE__, __LINE__, ## args )
+ 
+ const char* str_log_c (int lvl, const char* file, int line,
+@@ -50,7 +50,7 @@ const char* str_log_c (int lvl, const ch
+ 
+ #else // __GNUC__
+ void log_c (int lvl, const char* file, int line, const char* format, ...);
+-#define log(lvl, ...) \
++#define mylog(lvl, ...) \
+       if (lvl <= get_log_level()) log_c(lvl, __FILE__, __LINE__, __VA_ARGS__)
+ const char* str_log_c (int lvl, const char* file, int line,
+       const char* fortmat, ...);
Index: pkgsrc/net/paris-traceroute/patches/patch-src_paris-traceroute.cc
diff -u /dev/null pkgsrc/net/paris-traceroute/patches/patch-src_paris-traceroute.cc:1.1
--- /dev/null   Fri Mar 27 20:52:20 2020
+++ pkgsrc/net/paris-traceroute/patches/patch-src_paris-traceroute.cc   Fri Mar 27 20:52:19 2020
@@ -0,0 +1,55 @@
+$NetBSD: patch-src_paris-traceroute.cc,v 1.1 2020/03/27 20:52:19 joerg Exp $
+
+--- src/paris-traceroute.cc.orig       2020-03-27 18:20:36.333264404 +0000
++++ src/paris-traceroute.cc
+@@ -21,7 +21,7 @@ int main (int argc, char** argv) {
+ 
+   // Check CAP_NET_RAW capabilities
+   if (getuid() != 0) {
+-    //log(FATAL, "You must be root to run this program");
++    //mylog(FATAL, "You must be root to run this program");
+     //exit(-1);
+   }
+   
+@@ -53,7 +53,7 @@ int main (int argc, char** argv) {
+     algo = CONCURRENT_TRACERT;
+   } else if (strncmp(opts->algo, "scout", strlen(opts->algo)) == 0) {
+     if (strncmp(opts->protocol, "udp", 5) != 0) {
+-      log(WARN, "Scout algo is only usable with udp => hopbyhopalgo");
++      mylog(WARN, "Scout algo is only usable with udp => hopbyhopalgo");
+       algo = HOPBYHOP_TRACERT;
+     } else { 
+       algo = SCOUT_TRACERT;
+@@ -69,7 +69,7 @@ int main (int argc, char** argv) {
+     strcpy(opts->algo, "null");
+     // warn user.
+     // maybe he made a mistake when typing the so-long-algo-names !
+-    log(WARN, "Unknown algo (--algo=help for more help)");
++    mylog(WARN, "Unknown algo (--algo=help for more help)");
+   }
+ 
+       opts->algo_id = algo;
+@@ -79,7 +79,7 @@ int main (int argc, char** argv) {
+               FILE *targets = NULL;
+               if (opts->targets[0] != 0x00) {
+                       if ((targets = fopen(opts->targets, "r")) == NULL) {
+-                              log(FATAL, "can't open file\n");
++                              mylog(FATAL, "can't open file\n");
+                       }
+               }
+               
+@@ -172,12 +172,12 @@ int main (int argc, char** argv) {
+             // Execute concurrent traceroute
+             int reply_ttl = traceroute->getHopInfo(0, 0)->reply_ttl;
+             int ttl_dest  = opts->ttl_max - reply_ttl + 1;
+-            log(WARN, "ttl of the destination is %d (%d)", ttl_dest, reply_ttl);
++            mylog(WARN, "ttl of the destination is %d (%d)", ttl_dest, reply_ttl);
+             delete traceroute;
+             traceroute = new ConcurrentTracert(opts, ttl_dest);
+           } else {
+             // Execute hop-by-hop traceroute
+-            log(INFO, "Concurrent algo is not usable => use hopbyhop algo");
++            mylog(INFO, "Concurrent algo is not usable => use hopbyhop algo");
+             delete traceroute;
+             traceroute = new HopByHopTracert(opts);
+           }
Index: pkgsrc/net/paris-traceroute/patches/patch-src_tupleroute.cc
diff -u /dev/null pkgsrc/net/paris-traceroute/patches/patch-src_tupleroute.cc:1.1
--- /dev/null   Fri Mar 27 20:52:20 2020
+++ pkgsrc/net/paris-traceroute/patches/patch-src_tupleroute.cc Fri Mar 27 20:52:19 2020
@@ -0,0 +1,68 @@
+$NetBSD: patch-src_tupleroute.cc,v 1.1 2020/03/27 20:52:19 joerg Exp $
+
+--- src/tupleroute.cc.orig     2020-03-27 18:20:38.643120847 +0000
++++ src/tupleroute.cc
+@@ -20,7 +20,7 @@ int main (int argc, char** argv) {
+   
+   // Check CAP_NET_RAW capabilities
+   if (getuid() != 0) {
+-    //log(FATAL, "You must be root to run this program");
++    //mylog(FATAL, "You must be root to run this program");
+     //exit(-1);
+   }
+ 
+@@ -45,7 +45,7 @@ int main (int argc, char** argv) {
+     algo = CONCURRENT_TRACERT;
+   } else if (strncmp(opts->algo, "scout", strlen(opts->algo)) == 0) {
+     if (strncmp(opts->protocol, "udp", 5) != 0) {
+-      log(INFO, "Scout algo is only usable with udp => hopbyhopalgo");
++      mylog(INFO, "Scout algo is only usable with udp => hopbyhopalgo");
+       algo = HOPBYHOP_TRACERT;
+     } else algo = SCOUT_TRACERT;
+   } else if (strncmp(opts->algo, "exhaustive", strlen(opts->algo)) == 0) {
+@@ -54,7 +54,7 @@ int main (int argc, char** argv) {
+     strcpy(opts->algo, "null");
+     // warn user.
+     // maybe he made a mistake when typing the so-long-algo-names !
+-    log(WARN, "Unknown algo (--algo=help for more help)");
++    mylog(WARN, "Unknown algo (--algo=help for more help)");
+   }
+ 
+   // Create algo structures
+@@ -103,12 +103,12 @@ int main (int argc, char** argv) {
+       // Execute concurrent traceroute
+       int reply_ttl = traceroute->getHopInfo(0, 0)->reply_ttl;
+       int ttl_dest  = opts->ttl_max - reply_ttl + 1;
+-      log(INFO, "ttl of the destination is %d", ttl_dest);
++      mylog(INFO, "ttl of the destination is %d", ttl_dest);
+       delete traceroute;
+       traceroute = new ConcurrentTracert(opts, ttl_dest);
+     } else {
+       // Execute hop-by-hop traceroute
+-      log(INFO, "Concurrent algo is not usable => use hopbyhop algo");
++      mylog(INFO, "Concurrent algo is not usable => use hopbyhop algo");
+       delete traceroute;
+       traceroute = new HopByHopTracert(opts);
+     }
+@@ -125,17 +125,17 @@ int main (int argc, char** argv) {
+   //else
+   //  printf("Output disabled for ExhaustiveTracert\n");
+   
+-  log(INFO, "output done");
++  mylog(INFO, "output done");
+   
+   // Free ressources
+   delete icmp_server;
+-  log(INFO, "deleted icmp_server");
++  mylog(INFO, "deleted icmp_server");
+   if (tcp_server != NULL) delete tcp_server;
+   delete traceroute;
+-  log(INFO, "deleted traceroute");
++  mylog(INFO, "deleted traceroute");
+   delete opts;
+ 
+-  log(INFO, "exiting...");
++  mylog(INFO, "exiting...");
+   
+   return 0;
+ }



Home | Main Index | Thread Index | Old Index