Commit 05456fd2 authored by Mike Hibler's avatar Mike Hibler

Big Ass Hack(tm):

Add a "log" message which allows a client to send some text to TMCD which
in turns appends it to a project/experiment specific log file.  Adds all new
DoS routes to TMCD, and should perhaps be split off into its own daemon,
but for now it gives a way for console-less sharks to report what they did.
parent c934abf7
...@@ -2,4 +2,11 @@ ...@@ -2,4 +2,11 @@
* Insert Copyright Here. * Insert Copyright Here.
*/ */
#ifdef LBS
#define MASTERNODE "206.163.153.25"
#else
#define MASTERNODE "boss.emulab.net"
#endif
#define TBSERVER_PORT 7777 #define TBSERVER_PORT 7777
#define MYBUFSIZE 1024
...@@ -18,12 +18,6 @@ ...@@ -18,12 +18,6 @@
#include <netdb.h> #include <netdb.h>
#include "decls.h" #include "decls.h"
#ifdef LBS
#define MASTERNODE "206.163.153.25"
#else
#define MASTERNODE "boss.emulab.net"
#endif
void sigcatcher(int foo); void sigcatcher(int foo);
int int
...@@ -36,7 +30,7 @@ main(int argc, char **argv) ...@@ -36,7 +30,7 @@ main(int argc, char **argv)
#endif #endif
struct hostent *he; struct hostent *he;
struct in_addr serverip; struct in_addr serverip;
char buf[BUFSIZ], *bp, *response = ""; char buf[MYBUFSIZE], *bp, *response = "";
#ifdef UDPTEST #ifdef UDPTEST
int useudp = 0; int useudp = 0;
void doudp(int argc, char **argv); void doudp(int argc, char **argv);
...@@ -190,7 +184,7 @@ doudp(int argc, char **argv) ...@@ -190,7 +184,7 @@ doudp(int argc, char **argv)
struct sockaddr_in name, client; struct sockaddr_in name, client;
struct hostent *he; struct hostent *he;
struct in_addr serverip; struct in_addr serverip;
char buf[BUFSIZ], *bp, *response = ""; char buf[MYBUFSIZE], *bp, *response = "";
if (argc < 2 || argc > 3) { if (argc < 2 || argc > 3) {
fprintf(stderr, "usage: %s <command>\n", argv[0]); fprintf(stderr, "usage: %s <command>\n", argv[0]);
......
This diff is collapsed.
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment