dockapps/wmppp.app/wmppp/getmodemspeed.c
Carlos R. Mafra 21625f40b5 Initial dockapps git repo
I tried to get the latest versions from dockapps.org, but I haven't
tested any of them.

More dockapps will be added as time permits.
2011-03-25 19:45:13 +01:00

18 lines
244 B
C

#include <stdio.h>
int main(void) {
FILE *fd;
char temp[256];
fd = popen("tac /etc/ppp/connect-errors | grep '['CONNECT'|'CARRIER']' | head -1", "r");
while (fgets(temp, 256, fd)) {
printf("%s", temp);
}
pclose(fd);
return 0;
}