]> www.hackdaworld.org Git - my-code/ivac.git/commitdiff
MAX_SIZE 1400
authorhackbard <hackbard>
Fri, 10 Jan 2003 15:28:48 +0000 (15:28 +0000)
committerhackbard <hackbard>
Fri, 10 Jan 2003 15:28:48 +0000 (15:28 +0000)
receive.c

index 105a81c2e27a42279b79e223715598d39b6b8b30..9bd11f86cda602b9c9a3a7ff64964c832704a5b8 100644 (file)
--- a/receive.c
+++ b/receive.c
@@ -26,6 +26,9 @@
 /* read, close */
 #include <unistd.h>
 
 /* read, close */
 #include <unistd.h>
 
+/* defines ... */
+#define MAX_SIZE 1400
+
 int main(int argc, char *argv[]) {
   int receive_fd;
   struct sockaddr_in target_addr;
 int main(int argc, char *argv[]) {
   int receive_fd;
   struct sockaddr_in target_addr;
@@ -54,7 +57,7 @@ int main(int argc, char *argv[]) {
 
   receive_bytes=1;
   while(receive_bytes>0) {
 
   receive_bytes=1;
   while(receive_bytes>0) {
-       unsigned char buf[1000];
+       unsigned char buf[MAX_SIZE];
        receive_bytes=recv(receive_fd,buf,sizeof(buf),0);
         write_bytes=write(1,buf,receive_bytes);
   }
        receive_bytes=recv(receive_fd,buf,sizeof(buf),0);
         write_bytes=write(1,buf,receive_bytes);
   }