ViewVC Help
View File | Revision Log | Show Annotations | Download File
/cvs/deliantra/server/socket/lowlevel.C
(Generate patch)

Comparing deliantra/server/socket/lowlevel.C (file contents):
Revision 1.71 by root, Mon Oct 12 14:00:59 2009 UTC vs.
Revision 1.72 by root, Tue Oct 13 18:20:08 2009 UTC

255 pl && pl->ob ? &pl->ob->name : "[anonymous]"); 255 pl && pl->ob ? &pl->ob->name : "[anonymous]");
256 destroy (); 256 destroy ();
257 return false; 257 return false;
258 } 258 }
259 259
260 uint8_t save_byte = inbuf [pkt_len]; // rather ugly
260 inbuf [pkt_len] = 0; /* Terminate buffer - useful for string data */ 261 inbuf [pkt_len] = 0; /* temporarily terminate buffer - useful for string data */
261 262
262 /* First, break out beginning word. There are at least 263 /* First, break out beginning word. There are at least
263 * a few commands that do not have any paremeters. If 264 * a few commands that do not have any paremeters. If
264 * we get such a command, don't worry about trying 265 * we get such a command, don't worry about trying
265 * to break it up. 266 * to break it up.
289 goto next_packet; 290 goto next_packet;
290 } 291 }
291 292
292 // If we get here, we didn't find a valid command. 293 // If we get here, we didn't find a valid command.
293 send_packet_printf ("drawinfo %d ERROR: command '%s' not supported.", NDI_RED | NDI_REPLY, (char *)inbuf + 2); 294 send_packet_printf ("drawinfo %d ERROR: command '%s' not supported.", NDI_RED | NDI_REPLY, (char *)inbuf + 2);
295
294next_packet: 296next_packet:
297 inbuf [pkt_len] = save_byte; // rather ugly
295 skip_packet (pkt_len); 298 skip_packet (pkt_len);
296 299
297 // input buffer has space again 300 // input buffer has space again
298 socket_ev.poll (socket_ev.poll () | EV_READ); 301 socket_ev.poll (socket_ev.poll () | EV_READ);
299 302

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines