From 1245fbd2a8d60bab7b16b8a1d3c0122fee72f53f Mon Sep 17 00:00:00 2001 From: Ralf Baechle Date: Wed, 5 Jun 2013 00:57:38 +0200 Subject: Nuke trailing whitespace. Signed-off-by: Ralf Baechle --- rose/Makefile.am | 6 +++--- rose/rose.4 | 2 +- rose/rsattach.c | 40 ++++++++++++++++++++-------------------- rose/rsdwnlnk.8 | 2 +- rose/rsdwnlnk.c | 10 +++++----- rose/rsmemsiz.c | 10 +++++----- rose/rsparms.c | 8 ++++---- rose/rsuplnk.c | 4 ++-- 8 files changed, 41 insertions(+), 41 deletions(-) (limited to 'rose') diff --git a/rose/Makefile.am b/rose/Makefile.am index 1729e9a..2a2e95b 100644 --- a/rose/Makefile.am +++ b/rose/Makefile.am @@ -1,9 +1,9 @@ -sbin_PROGRAMS = rsattach rsdwnlnk rsmemsiz rsparms rsuplnk +sbin_PROGRAMS = rsattach rsdwnlnk rsmemsiz rsparms rsuplnk LDADD = $(AX25_LIB) -rsmemsiz_LDADD = +rsmemsiz_LDADD = sbin_SCRIPTS = rsusers.sh @@ -13,7 +13,7 @@ dist_man_MANS = rose.4 rsattach.8 rsparms.8 rsdwnlnk.8 rsuplnk.8 EXTRA_DIST = $(sbin_SCRIPTS) INCLUDES = -DAX25_SYSCONFDIR=\""$(AX25_SYSCONFDIR)"\" \ - -DAX25_LOCALSTATEDIR=\""$(AX25_LOCALSTATEDIR)"\" + -DAX25_LOCALSTATEDIR=\""$(AX25_LOCALSTATEDIR)"\" AX25_SYSCONFDIR=${sysconfdir}/ax25/ AX25_LOCALSTATEDIR=${localstatedir}/ax25/ diff --git a/rose/rose.4 b/rose/rose.4 index a06f324..7904017 100644 --- a/rose/rose.4 +++ b/rose/rose.4 @@ -24,7 +24,7 @@ Rose has some unusual properties. Notably in a multi-user system an AX.25 address is often associated with a user, and some users may not have such an association. a set of ioctl calls are provided to manage an association table. -.LP +.LP Rose supports the following socket options for SOL_ROSE. ROSE_T1 is the T11/T21 timer in 1/10ths of a second, ROSE_T2 is the T12/T22 timer in 1/10ths of a second. ROSE_T3, is the T13/T23 timer in 1/10ths of a second. diff --git a/rose/rsattach.c b/rose/rsattach.c index 924d152..62892d8 100644 --- a/rose/rsattach.c +++ b/rose/rsattach.c @@ -35,7 +35,7 @@ int readconfig(char *port) FILE *fp; char buffer[90], *s; int n = 0; - + if ((fp = fopen(CONF_RSPORTS_FILE, "r")) == NULL) { fprintf(stderr, "rsattach: cannot open rsports file\n"); return FALSE; @@ -43,7 +43,7 @@ int readconfig(char *port) while (fgets(buffer, 90, fp) != NULL) { n++; - + if ((s = strchr(buffer, '\n')) != NULL) *s = '\0'; @@ -54,10 +54,10 @@ int readconfig(char *port) fprintf(stderr, "rsattach: unable to parse line %d of the rsports file\n", n); return FALSE; } - + if (strcmp(s, port) != 0) continue; - + if ((s = strtok(NULL, " \t\r\n")) == NULL) { fprintf(stderr, "rsattach: unable to parse line %d of the rsports file\n", n); return FALSE; @@ -66,14 +66,14 @@ int readconfig(char *port) address = strdup(s); fclose(fp); - + return TRUE; } - + fclose(fp); fprintf(stderr, "rsattach: cannot find port %s in rsports\n", port); - + return FALSE; } @@ -82,7 +82,7 @@ int getfreedev(char *dev) struct ifreq ifr; int fd; int i; - + if ((fd = socket(AF_INET, SOCK_DGRAM, 0)) < 0) { perror("rsattach: socket"); return FALSE; @@ -91,7 +91,7 @@ int getfreedev(char *dev) for (i = 0; i < 6; i++) { sprintf(dev, "rose%d", i); strcpy(ifr.ifr_name, dev); - + if (ioctl(fd, SIOCGIFFLAGS, &ifr) < 0) { perror("rsattach: SIOCGIFFLAGS"); return FALSE; @@ -113,17 +113,17 @@ int startiface(char *dev, struct hostent *hp) struct ifreq ifr; char addr[5]; int fd; - + if ((fd = socket(AF_INET, SOCK_DGRAM, 0)) < 0) { perror("rsattach: socket"); return FALSE; } strcpy(ifr.ifr_name, dev); - + if (hp != NULL) { ifr.ifr_addr.sa_family = AF_INET; - + ifr.ifr_addr.sa_data[0] = 0; ifr.ifr_addr.sa_data[1] = 0; ifr.ifr_addr.sa_data[2] = hp->h_addr_list[0][0]; @@ -143,7 +143,7 @@ int startiface(char *dev, struct hostent *hp) ifr.ifr_hwaddr.sa_family = ARPHRD_ROSE; memcpy(ifr.ifr_hwaddr.sa_data, addr, 5); - + if (ioctl(fd, SIOCSIFHWADDR, &ifr) != 0) { perror("rsattach: SIOCSIFHWADDR"); return FALSE; @@ -169,12 +169,12 @@ int startiface(char *dev, struct hostent *hp) perror("rsattach: SIOCSIFFLAGS"); return FALSE; } - + close(fd); - + return TRUE; } - + int main(int argc, char *argv[]) { @@ -199,7 +199,7 @@ int main(int argc, char *argv[]) return 1; } } - + if ((argc - optind) != 1) { fprintf(stderr, "usage: rsattach [-i inetaddr] [-v] port\n"); return 1; @@ -212,11 +212,11 @@ int main(int argc, char *argv[]) fprintf(stderr, "rsattach: cannot find free Rose device\n"); return 1; } - + if (!startiface(dev, hp)) - return 1; + return 1; printf("Rose port %s bound to device %s\n", argv[optind], dev); - + return 0; } diff --git a/rose/rsdwnlnk.8 b/rose/rsdwnlnk.8 index f0d4c2d..db1a601 100644 --- a/rose/rsdwnlnk.8 +++ b/rose/rsdwnlnk.8 @@ -23,7 +23,7 @@ you need an entry in to listen for incoming ROSE connections to any callsigns that are not matched by the more specific ROSE entries. In the example below, I will be listening for ROSE connections on my ROSE port rs144, the exiting AX.25 -connection will be via the associated AX.25 port, 144, using the callsign +connection will be via the associated AX.25 port, 144, using the callsign KE4GAJ-10. Please note that the callsign should be on the same line as the rest of the command, it may be wrapped onto the next line on your screen. .LP diff --git a/rose/rsdwnlnk.c b/rose/rsdwnlnk.c index 9ff6f31..8c7bb08 100644 --- a/rose/rsdwnlnk.c +++ b/rose/rsdwnlnk.c @@ -114,7 +114,7 @@ int main(int argc, char **argv) return 1; } axconnect.fsa_digipeater[n].ax25_call[6] |= AX25_HBIT; - n++; + n++; } /* @@ -127,7 +127,7 @@ int main(int argc, char **argv) return 1; } axconnect.fsa_digipeater[n].ax25_call[6] |= AX25_HBIT; - n++; + n++; /* * And my local ROSE callsign. @@ -215,9 +215,9 @@ int main(int argc, char **argv) close(s); write(STDOUT_FILENO, buffer, strlen(buffer)); - + sleep(20); - + return 0; } @@ -236,7 +236,7 @@ int main(int argc, char **argv) FD_ZERO(&read_fd); FD_SET(STDIN_FILENO, &read_fd); FD_SET(s, &read_fd); - + select(s + 1, &read_fd, NULL, NULL, NULL); if (FD_ISSET(s, &read_fd)) { diff --git a/rose/rsmemsiz.c b/rose/rsmemsiz.c index c71737c..bdddb45 100644 --- a/rose/rsmemsiz.c +++ b/rose/rsmemsiz.c @@ -54,7 +54,7 @@ static char buf[300]; int uptime(double *uptime_secs, double *idle_secs) { double up=0, idle=0; - + FILE_TO_BUF(UPTIME_FILE) if (sscanf(buf, "%lf %lf", &up, &idle) < 2) { fprintf(stdout, "ERROR: Bad data in %s\r", UPTIME_FILE); @@ -67,7 +67,7 @@ int uptime(double *uptime_secs, double *idle_secs) { int loadavg(double *av1, double *av5, double *av15) { double avg_1=0, avg_5=0, avg_15=0; - + FILE_TO_BUF(LOADAVG_FILE) if (sscanf(buf, "%lf %lf %lf", &avg_1, &avg_5, &avg_15) < 3) { fprintf(stdout, "ERROR: Bad data in %s\r", LOADAVG_FILE); @@ -83,7 +83,7 @@ int loadavg(double *av1, double *av5, double *av15) { [