httpd-cvs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From traw...@locus.apache.org
Subject cvs commit: apache-2.0/src/lib/apr/test testsf.c
Date Fri, 03 Nov 2000 18:10:54 GMT
trawick     00/11/03 10:10:53

  Modified:    src/lib/apr/test testsf.c
  Log:
  Update the apr_sendfile() test program to expect APR_EOF/0 bytes
  instead of APR_SUCCESS/0 bytes at EOF.
  
  Revision  Changes    Path
  1.11      +8 -8      apache-2.0/src/lib/apr/test/testsf.c
  
  Index: testsf.c
  ===================================================================
  RCS file: /home/cvs/apache-2.0/src/lib/apr/test/testsf.c,v
  retrieving revision 1.10
  retrieving revision 1.11
  diff -u -r1.10 -r1.11
  --- testsf.c	2000/11/03 18:05:09	1.10
  +++ testsf.c	2000/11/03 18:10:52	1.11
  @@ -455,15 +455,15 @@
   
       bytes_read = 1;
       rv = apr_recv(sock, buf, &bytes_read);
  -    if (rv != APR_SUCCESS) {
  -        fprintf(stderr, "apr_recv()->%d/%s\n",
  +    if (rv != APR_EOF) {
  +        fprintf(stderr, "apr_recv()->%d/%s (expected APR_EOF)\n",
                   rv,
   		apr_strerror(rv, buf, sizeof buf));
           exit(1);
       }
       if (bytes_read != 0) {
  -        fprintf(stderr, "We expected the EOF condition on the connected\n"
  -                "socket but instead we read %ld bytes.\n",
  +        fprintf(stderr, "We expected to get 0 bytes read with APR_EOF\n"
  +                "but instead we read %ld bytes.\n",
                   (long int)bytes_read);
           exit(1);
       }
  @@ -694,15 +694,15 @@
           
       bytes_read = 1;
       rv = apr_recv(newsock, buf, &bytes_read);
  -    if (rv != APR_SUCCESS) {
  -        fprintf(stderr, "apr_recv()->%d/%s\n",
  +    if (rv != APR_EOF) {
  +        fprintf(stderr, "apr_recv()->%d/%s (expected APR_EOF)\n",
                   rv,
   		apr_strerror(rv, buf, sizeof buf));
           exit(1);
       }
       if (bytes_read != 0) {
  -        fprintf(stderr, "We expected the EOF condition on the connected\n"
  -                "socket but instead we read %ld bytes (%c).\n",
  +        fprintf(stderr, "We expected to get 0 bytes read with APR_EOF\n"
  +                "but instead we read %ld bytes (%c).\n",
                   (long int)bytes_read, buf[0]);
           exit(1);
       }
  
  
  

Mime
View raw message