From: Roger Wolff Date: Sat, 4 Mar 2000 00:00:00 +0000 (+0000) Subject: mtr v0.42 X-Git-Tag: v0.42^0 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=325d12a87a1263a24e7fe0652572fc452e974179;p=thirdparty%2Fmtr.git mtr v0.42 - Compile misc. source: ftp://ftp.bitwizard.nl/mtr/mtr-0.42.tar.gz --- diff --git a/README b/README index 92544d4..bc428fc 100644 --- a/README +++ b/README @@ -18,14 +18,13 @@ INSTALLING Slightly more hints are in the file INSTALL. If this doesn't work you could try reading that too.... - To begin compiling mtr, first use the included configure script: - - ./configure - - The configure script will generate a Makefile. Build mtr: + Compiling mtr should be as simple as: make + It should first call the "configure" script and then run "make" again + with the makefile that "configure" just generated. + After compiling, install: make install @@ -40,9 +39,19 @@ INSTALLING It seems the --no_gtk (whatever) doesn't work. Feel free to submit a patch for this, I'm not that familiar with autoconf (it works for - me :-). - - + me :-). + + On Solaris (and possibly other systems) the "gtk" library may be + installed in a directory where the dynamic linker refuses to look when + a binary is setuid. Roman Shterenzon reports that adding + -Wl,-rpath=/usr/lib + to the commandline will work if you are using gnu LD. He tells me that + you're out of luck when you use the sun LD. That's not quite true, as + you can move the gtk libraries to /usr/lib instead of leaving them in + /usr/local/lib. (when the ld tells you that /usr/local/lib is untrusted + and /usr/lib is trusted, and you trust hte gtk libs enough to want them + in a setuid program, then there is something to say for moving them + to the "trusted" directory.) WHERE CAN I GET THE LATEST VERSION OR MORE INFORMATION? diff --git a/TODO b/TODO index 2090d2b..2c2b34d 100644 --- a/TODO +++ b/TODO @@ -38,6 +38,8 @@ Oh, Feel free to provide suggestions for this list. - allow "keyboard navigation" in the GTK version. + - Keep all packets and make the "best" and "worst" columns show the + xx-th percentile.... - Bugs to fix? diff --git a/configure.in b/configure.in index 840d3df..d6b9d5e 100644 --- a/configure.in +++ b/configure.in @@ -1,5 +1,5 @@ AC_INIT(mtr.c) -AM_INIT_AUTOMAKE(mtr, 0.41) +AM_INIT_AUTOMAKE(mtr, 0.42) AC_SUBST(GTK_OBJ) AC_SUBST(CURSES_OBJ) diff --git a/display.h b/display.h index 6b091d7..33f6bcf 100644 --- a/display.h +++ b/display.h @@ -32,4 +32,4 @@ int display_keyaction(); void display_loop(); void display_clear(); -int display_mode; +extern int display_mode; diff --git a/mtr.c b/mtr.c index 8234b1b..7af7ef8 100644 --- a/mtr.c +++ b/mtr.c @@ -37,6 +37,7 @@ #endif int DisplayMode; +int display_mode; int Interactive = 1; int PrintVersion = 0; int PrintHelp = 0; @@ -158,7 +159,7 @@ int main(int argc, char **argv) { net_preopen_result = net_preopen (); /* Now drop to user permissions */ - if(seteuid(getuid())) { + if(setuid(getuid())) { printf("mtr: Unable to drop permissions.\n"); exit(1); } diff --git a/net.c b/net.c index 46f4bb1..496be26 100644 --- a/net.c +++ b/net.c @@ -282,7 +282,7 @@ void net_process_return() { header = (struct ICMPHeader *)(packet + sizeof(struct IPHeader)); if(header->type == ICMP_ECHOREPLY) { - if(header->id != getpid()) + if(header->id != (uint16)getpid()) return; net_process_ping(header->sequence, fromaddr.sin_addr.s_addr, now); @@ -293,7 +293,7 @@ void net_process_return() { header = (struct ICMPHeader *)(packet + sizeof(struct IPHeader) + sizeof(struct ICMPHeader) + sizeof(struct IPHeader)); - if(header->id != getpid()) + if(header->id != (uint16)getpid()) return; net_process_ping(header->sequence, fromaddr.sin_addr.s_addr, now);