summaryrefslogtreecommitdiffstats
path: root/listen
Commit message (Collapse)AuthorAgeFilesLines
* remove listen.1Thomas Osterried2016-07-041-105/+0
|
* Improved timestamps. With code and -t -tt -ttt ... option behaviour from ↵Thomas Osterried2016-07-041-2/+16
| | | | | | | | tcpdump. -> Without -t, listen now shows a timestamp. Signed-off-by: Thomas Osterried <ax25@x-berg.in-berlin.de>
* fixed segfault on -c option.root2016-07-041-2/+4
| | | | | | | has_colors() was called before initscr(). also added error message if terminal does not support colors (and then exit). Signed-off-by: root <root@db0fhn.ampr.org>
* Improved timestamps. With code and -t -tt -ttt ... option behaviour from ↵Thomas Osterried2016-07-044-22/+245
| | | | | | | | tcpdump. -> Without -t, listen now shows a timestamp. Signed-off-by: Thomas Osterried <ax25@x-berg.in-berlin.de>
* listen -a shows on segmented packets ok, but shows also the defragmented,Thomas Osterried2016-03-121-0/+28
| | | | | | | | | | | | | | | | | | | | | | | | | | packet, but garbled: bpq2: fm DL9SAU to DL9SAU-15 ctl I00+ pid=8(segment) len 4 remain 0 0000 E2 E3 E4 | ... Reason: the defragmented packet is passed to netif_rx(skb). It has skb->protocol = htons(ETH_P_IP), but still belongs to ifr.ifr_hwaddr.sa_family == AF_AX25. listen -a looks for every iface with like ifr.ifr_hwaddr.sa_family == AF_AX25 and thus gets the desegmented packet. This desegmented packet has already lost his ax25 header information (it's the IP datagram that netif_rx sees), prefixed by AX25_P_IP = 0xcc: strace: recvfrom(3, "\0\210\230r\246\202\252\340\210\230r\246\202\252\177\314\10\201\314E\0\1\1\0\32\0\0?\1!\327,\200\200\n,\200\200\1\0\0\347\300\21\6\0\1\26\23\303V.. recvfrom(3, "\314E\0\1\1\0\32\0\0?\1!\327,\200\200\n,\200\200\1\0\0\347\300\21\6\0\1\26\23\303V.. \314 == 0xcc == AX25_P_IP We can make safely make the assumption for first byte == 0xcc and length > 2, that we safeley can detect those IP frames, and then ignore it. Signed-off-by: Thomas Osterried <ax25@x-berg.in-berlin.de>
* listen: Fix signedness compiler warnings.Ralf Baechle2015-06-084-8/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | make[2]: Entering directory '/home/ralf/src/ax25/ax25-apps/listen' gcc -DHAVE_CONFIG_H -I. -I.. -g -O2 -Wall -MT listen.o -MD -MP -MF .deps/listen.Tpo -c -o listen.o listen.c listen.c: In function ‘ascii_dump’: listen.c:231:4: warning: pointer targets in passing argument 2 of ‘__builtin_strncat’ differ in signedness [-Wpointer-sign] strncat(buf, &c, 1); ^ listen.c:231:4: note: expected ‘const char *’ but argument is of type ‘unsigned char *’ listen.c: In function ‘hex_dump’: listen.c:282:8: warning: pointer targets in assignment differ in signedness [-Wpointer-sign] data2 = data; ^ [...] gcc -DHAVE_CONFIG_H -I. -I.. -g -O2 -Wall -MT rosedump.o -MD -MP -MF .deps/rosedump.Tpo -c -o rosedump.o rosedump.c rosedump.c: In function ‘facility’: rosedump.c:331:9: warning: pointer targets in assignment differ in signedness [-Wpointer-sign] factot = data; ^ rosedump.c:398:11: warning: pointer targets in assignment differ in signedness [-Wpointer-sign] for (d = data, l = 0; l < lgaddcall; ^ rosedump.c:406:28: warning: pointer targets in passing argument 1 of ‘dump_ax25_call’ differ in signedness [-Wpointer-sign] dump_ax25_call(d, 7)); ^ rosedump.c:296:14: note: expected ‘unsigned char *’ but argument is of type ‘char *’ static char *dump_ax25_call(unsigned char *data, int l_data) ^ rosedump.c:410:28: warning: pointer targets in passing argument 1 of ‘dump_ax25_call’ differ in signedness [-Wpointer-sign] dump_ax25_call(d, 7)); ^ rosedump.c:296:14: note: expected ‘unsigned char *’ but argument is of type ‘char *’ static char *dump_ax25_call(unsigned char *data, int l_data) ^ rosedump.c:438:4: warning: pointer targets in passing argument 2 of ‘__builtin_strncpy’ differ in signedness [-Wpointer-sign] strncpy(indorig, data, lgadind); ^ rosedump.c:438:4: note: expected ‘const char *’ but argument is of type ‘unsigned char *’ rosedump.c:441:4: warning: pointer targets in passing argument 2 of ‘__builtin_strncpy’ differ in signedness [-Wpointer-sign] strncpy(inddest, data, lgadind); ^ rosedump.c:441:4: note: expected ‘const char *’ but argument is of type ‘unsigned char *’ rosedump.c:451:14: warning: pointer targets in passing argument 1 of ‘data_dump’ differ in signedness [-Wpointer-sign] data_dump(factot, lgtot, 1); ^ In file included from rosedump.c:11:0: listen.h:31:6: note: expected ‘unsigned char *’ but argument is of type ‘char *’ void data_dump(unsigned char *, int, int); ^ [...] gcc -DHAVE_CONFIG_H -I. -I.. -g -O2 -Wall -MT utils.o -MD -MP -MF .deps/utils.Tpo -c -o utils.o utils.c utils.c: In function ‘lprintf’: utils.c:49:10: warning: pointer targets in assignment differ in signedness [-Wpointer-sign] for (p = str; *p != '\0'; p++) { ^ utils.c:71:10: warning: pointer targets in assignment differ in signedness [-Wpointer-sign] for (p = str; *p != '\0'; p++) ^ [...] make[2]: Leaving directory '/home/ralf/src/ax25/ax25-apps/listen' Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
* listen/opentracdump.c: Fix signedness compiler warnings.Ralf Baechle2015-06-081-10/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | gcc -DHAVE_CONFIG_H -I. -I.. -g -O2 -Wall -MT opentracdump.o -MD -MP -MF .deps/opentracdump.Tpo -c -o opentracdump.o opentracdump.c opentracdump.c: In function ‘decode_origination’: opentracdump.c:70:9: warning: pointer targets in passing argument 1 of ‘strcpy’ differ in signedness [-Wpointer-sign] strcpy(entity_call, origin_call); ^ In file included from opentracdump.c:9:0: /usr/include/string.h:129:14: note: expected ‘char * restrict’ but argument is of type ‘unsigned char *’ extern char *strcpy (char *__restrict __dest, const char *__restrict __src) ^ opentracdump.c:70:22: warning: pointer targets in passing argument 2 of ‘strcpy’ differ in signedness [-Wpointer-sign] strcpy(entity_call, origin_call); ^ In file included from opentracdump.c:9:0: /usr/include/string.h:129:14: note: expected ‘const char * restrict’ but argument is of type ‘unsigned char *’ extern char *strcpy (char *__restrict __dest, const char *__restrict __src) ^ opentracdump.c: In function ‘decode_entityid’: opentracdump.c:86:10: warning: pointer targets in passing argument 1 of ‘strcpy’ differ in signedness [-Wpointer-sign] strcpy(entity_call, origin_call); ^ In file included from opentracdump.c:9:0: /usr/include/string.h:129:14: note: expected ‘char * restrict’ but argument is of type ‘unsigned char *’ extern char *strcpy (char *__restrict __dest, const char *__restrict __src) ^ opentracdump.c:86:23: warning: pointer targets in passing argument 2 of ‘strcpy’ differ in signedness [-Wpointer-sign] strcpy(entity_call, origin_call); ^ In file included from opentracdump.c:9:0: /usr/include/string.h:129:14: note: expected ‘const char * restrict’ but argument is of type ‘unsigned char *’ extern char *strcpy (char *__restrict __dest, const char *__restrict __src) ^ opentracdump.c: In function ‘decode_comment’: opentracdump.c:159:1: warning: pointer targets in passing argument 2 of ‘__builtin_strncpy’ differ in signedness [-Wpointer-sign] strncpy(comment, element, element_len); ^ opentracdump.c:159:1: note: expected ‘const char *’ but argument is of type ‘unsigned char *’ opentracdump.c: In function ‘decode_country’: opentracdump.c:195:1: warning: pointer targets in passing argument 2 of ‘__builtin_strncpy’ differ in signedness [-Wpointer-sign] strncpy(country, element, 2); ^ opentracdump.c:195:1: note: expected ‘const char *’ but argument is of type ‘unsigned char *’ opentracdump.c:198:2: warning: pointer targets in passing argument 2 of ‘__builtin_strncpy’ differ in signedness [-Wpointer-sign] strncpy(subdivision, element+2, element_len-2); ^ opentracdump.c:198:2: note: expected ‘const char *’ but argument is of type ‘unsigned char *’ opentracdump.c: In function ‘decode_displayname’: opentracdump.c:211:5: warning: pointer targets in passing argument 2 of ‘__builtin_strncpy’ differ in signedness [-Wpointer-sign] strncpy(displayname, element, element_len); ^ opentracdump.c:211:5: note: expected ‘const char *’ but argument is of type ‘unsigned char *’ opentracdump.c: In function ‘decode_waypoint’: opentracdump.c:221:1: warning: pointer targets in passing argument 2 of ‘__builtin_strncpy’ differ in signedness [-Wpointer-sign] strncpy(waypoint, element, element_len); ^ opentracdump.c:221:1: note: expected ‘const char *’ but argument is of type ‘unsigned char *’ opentracdump.c: In function ‘decode_pathtrace’: opentracdump.c:255:23: warning: pointer targets in passing argument 1 of ‘extract_ssid’ differ in signedness [-Wpointer-sign] ssid = extract_ssid(callsign); ^ opentracdump.c:30:5: note: expected ‘unsigned char *’ but argument is of type ‘char *’ int extract_ssid(unsigned char *call) { ^ opentracdump.c: In function ‘decode_acreg’: opentracdump.c:315:1: warning: pointer targets in passing argument 2 of ‘__builtin_strncpy’ differ in signedness [-Wpointer-sign] strncpy(nnumber, element, element_len); ^ opentracdump.c:315:1: note: expected ‘const char *’ but argument is of type ‘unsigned char *’ opentracdump.c: In function ‘decode_maidenhead’: opentracdump.c:406:3: warning: pointer targets in passing argument 2 of ‘__builtin_strncpy’ differ in signedness [-Wpointer-sign] strncpy(maidenhead, element, element_len); ^ opentracdump.c:406:3: note: expected ‘const char *’ but argument is of type ‘unsigned char *’ opentracdump.c: In function ‘opentrac_dump’: opentracdump.c:452:9: warning: pointer targets in passing argument 1 of ‘strcpy’ differ in signedness [-Wpointer-sign] strcpy(origin_call, "SENDER"); /* Listen doesn't tell us the sender */ ^ In file included from opentracdump.c:9:0: /usr/include/string.h:129:14: note: expected ‘char * restrict’ but argument is of type ‘unsigned char *’ extern char *strcpy (char *__restrict __dest, const char *__restrict __src) ^ Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
* Reformat consistently. Strictly whitespace changes only.Ralf Baechle2015-05-024-122/+122
| | | | | | | Indentation by tabs only. Move case labels in switches are on the same level as the switch keyword. Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
* Remove parenthesis around arguments of return statements.Ralf Baechle2015-05-022-3/+3
| | | | Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
* Use tabs for indentation, not spaces.Ralf Baechle2015-05-021-2/+2
| | | | Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
* Nuke trailing whitespace.Ralf Baechle2015-05-026-12/+12
| | | | Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
* ax25dump: Fix warning about set but not used variables.Ralf Baechle2013-06-171-0/+2
| | | | | | | | | | | | gcc -DHAVE_CONFIG_H -I. -I.. -O2 -Wall -Wno-pointer-sign -MT ax25dump.o -MD -MP -MF .deps/ax25dump.Tpo -c -o ax25dump.o ax25dump.c ax25dump.c: In function ‘ax25_dump’: ax25dump.c:170:10: warning: ‘ns’ may be used uninitialized in this function [-Wmaybe-uninitialized] ax25dump.c:167:10: warning: ‘nr’ may be used uninitialized in this function [-Wmaybe-uninitialized] GCC isn't quite smart enough to figure out that this warning is bogus. Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
* Fix warnings about set but not used variables.Ralf Baechle2013-06-171-8/+1
| | | | | | | | | | | gcc -DHAVE_CONFIG_H -I. -I.. -O2 -Wall -Wno-pointer-sign -MT rosedump.o -MD -MP -MF .deps/rosedump.Tpo -c -o rosedump.o rosedump.c rosedump.c: In function ‘rose_dump’: rosedump.c:57:17: warning: variable ‘dest’ set but not used [-Wunused-but-set-va riable] rosedump.c:56:17: warning: variable ‘source’ set but not used [-Wunused-but-set- variable] rosedump.c: In function ‘facility’: rosedump.c:329:12: warning: variable ‘lgaddr’ set but not used [-Wunused-but-set -variable] Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
* Listen: Fix test for tty's color capabilities.Ralf Baechle2013-06-161-1/+1
| | | | | | | | | | It was testing the address of the curses function has_color(), not its return value indicated by the following warning: utils.c: In function ‘initcolor’: utils.c:84:6: warning: the address of ‘has_colors’ will always evaluate as ‘true’ [-Waddress] Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
* Weed out all use of RCS strings.Ralf Baechle2013-06-058-16/+0
| | | | | | | Their value has always been dubious and git doesn't support them so let's get rid of the clutter. Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
* Ignore even more generated files.Ralf Baechle2013-06-041-4/+1
| | | | Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
* Convert .cvsignore files to .gitignoreRalf Baechle2013-06-041-2/+2
| | | | Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
* Fix build of man pages when building in a separate build directory.Ralf Baechle2013-06-041-1/+1
|
* Now debian license policy compliant:Thomas Osterried2012-05-211-2/+23
| | | | Relicense listen/ripdump.c to permit commercial use and distribution.
* Apply program name transformations also to man page content.Ralf Baechle2011-12-112-9/+26
| | | | | | For now these options are just honored for the call.1 and listen.1 man pages because these days these two programs generally get renamed to avoid naming conflicts with other programs.
* The last patch introduced cosmetic errors likeThomas Osterried2010-06-051-16/+28
| | | | | | | | | | | | GIFADDR: Bad file descriptor after signling termination with ^C In detail: close(3) = 0 sigreturn() = ? (mask now []) ioctl(3, SIOCGIFHWADDR, {ifr_name="eth0", ???}) = -1 EBADF (Bad file descriptor) -> The interrupt handler introduced concurrency issues ;) The patch caused only unexpected behaviour; no security problems. This new patch fixes this problem.
* Don't abort on SIGWINCH. Cleanly terminate on SIGINT and SIGTERM.Ralf Baechle2010-05-301-4/+34
| | | | Patch from Michael Stuermer <ms@mallorn.de> with a few touchups be me.
* Remove use of backwards compatibility header name.Ralf Baechle2009-06-211-4/+0
| | | | | | Glibc as old as 2.2 provides working headers under the right name and if not libax25 would install headers under the right name so this has become redundant and ugly.
* Ignore a few more generated files.Ralf Baechle2009-06-191-0/+1
|
* Remove all generated files.Ralf Baechle2009-06-191-539/+0
| | | | | | | | | | | | | | Keeping generated files in CVS doesn't only tend to produce large and cluttered files it also may result in build problems due to timestamps in the wrong order. So dump everything, update .cvsignore to ignore these files and resolve all warnings generated by autoreconf. From now on users of a CVS checkout should run the command autoreconf --install --force after having done a CVS checkout. For this to succeed automake, autoconf and libtool will have to be installed.
* Fix type of length argument to sockset syscalls.Ralf Baechle2009-06-141-1/+1
| | | | | | | | Various socket syscalls receive a length argument that should be a socklen_t rsp. a ptr to a socklen_t but instead int rsp. ptr to int were being passed. While in theory this was a bug it's harmless as dangerously large values would not be used but the issue manifested itself in a significant number of compilation warnings.
* Eleminate use of register keywordRalf Baechle2009-06-141-2/+2
| | | | | Any modern C compiler will just ignore register so it's just cluttering the screen.
* Added some includes. This fixes compilation problems in gentoo,Thomas Osterried2009-04-221-0/+1
| | | | and warnings.
* listen did not terminate if caller has died. fputs and fflushThomas Osterried2008-11-241-2/+4
| | | | return value EOF was not honored.
* changed mail addressThomas Osterried2008-04-272-3/+3
|
* updated addressesThomas Osterried2008-04-132-3/+3
|
* Fix warnings about // style comment. And remove some of the mostRalf Baechle2007-01-233-51/+47
| | | | pointless comments.
* Convert to autoconf 2.59. Delete junk from past centuries.Ralf Baechle2007-01-221-188/+291
|
* Minor bug fixes and some restructuringScott Miller N1VG2004-02-041-199/+118
|
* Added opentrac to listenCraig Small2004-02-047-220/+836
| | | | More autobbreak updating nightmares
* used PF_PACKET for SOCK_PACKET sockets, added time.h to axspawn.cMichael Taylor2002-11-031-1/+1
|
* changed fd_set variables around so no clashax25-apps-0.0.6Craig Small2002-03-041-2/+2
|
* Steve Frasers patch for ssid matching in ax25ipdCraig Small2002-01-121-1/+1
|
* * adjusted temp version back to 0.0.6Craig Small2002-01-072-1/+5
| | | | * Added \n to poll line
* remerged with terry indentsCraig Small2001-11-275-96/+168
|
* updated libtool, uniformly indented source, corrected small ax25mond ↵Terry Dawson VK2KTJ2001-09-1215-719/+790
| | | | Makefile bug
* Initial revisionax25-apps-0.0.5p2Craig Small2001-04-1011-26/+303
|
* Import ax25-apps 0.0.4 from tarballax25-apps-0.0.4Ralf Baechle1999-08-241-6/+6
|
* Import ax25-apps 0.0.3 from tarballax25-apps-0.0.3Ralf Baechle1999-08-104-53/+104
|
* Import ax25-apps 0.0.2 from tarballax25-apps-0.0.2Ralf Baechle1999-07-082-15/+1
|
* Import ax25-apps 0.0.1 from tarballax25-apps-0.0.1Ralf Baechle1999-06-0718-0/+2728