bug-cvs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[bug #38729] Problem in buffer.c if configuration not SHUTDOWN_SERVER an


From: Flávio Medeiros
Subject: [bug #38729] Problem in buffer.c if configuration not SHUTDOWN_SERVER and START_RSH_WITH_POPEN_RW is set.
Date: Sat, 13 Apr 2013 14:30:24 +0000
User-agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_8_3) AppleWebKit/537.31 (KHTML, like Gecko) Chrome/26.0.1410.65 Safari/537.31

URL:
  <http://savannah.nongnu.org/bugs/?38729>

                 Summary: Problem in buffer.c if configuration not
SHUTDOWN_SERVER and START_RSH_WITH_POPEN_RW is set. 
                 Project: Concurrent Versions System
            Submitted by: flaviommedeiros
            Submitted on: Sat 13 Apr 2013 02:30:22 PM GMT
                Category: Bug Fix (patch attached)
                Severity: 3 - Normal
              Item Group: None
                  Status: None
                 Privacy: Public
             Assigned to: None
             Open/Closed: Open
                 Release: 
         Discussion Lock: Any
           Fixed Release: None
   Fixed Feature Release: None

    _______________________________________________________

Details:

There is a problem in buffer.c (we saw it from version 1.11.17 to 1.11.23) if
configuration not SHUTDOWN_SERVER and START_RSH_WITH_POPEN_RW is set. We will
get an ELSE IF statement without an IF statement, which is not a valid
construction according to the C grammar (function: stdio_buffer_shutdown). The
original code is shown bellow and we sent a file attached
(buffer-modified-flaviomedeiros.c) with the correction. This problem has not
been submitted before.

if (buf->input) {

# ifdef SHUTDOWN_SERVER
        if (current_parsed_root->method != server_method)
# endif

# ifndef NO_SOCKET_TO_FD
        {
            /* shutdown() sockets */
            if (S_ISSOCK (s.st_mode))
                shutdown (fileno (bc->fp), 0);
        }
# endif /* NO_SOCKET_TO_FD */

# ifdef START_RSH_WITH_POPEN_RW
        /* Can't be set with SHUTDOWN_SERVER defined */
        else if (pclose (bc->fp) == EOF)
        {
            error (1, errno, "closing connection to %s",
                   current_parsed_root->hostname);
            closefp = 0;
        }
# endif /* START_RSH_WITH_POPEN_RW */


    }



    _______________________________________________________

File Attachments:


-------------------------------------------------------
Date: Sat 13 Apr 2013 02:30:22 PM GMT  Name: buffer-modified-flaviomedeiros.c 
Size: 43kB   By: flaviommedeiros
The file (buffer-modified-flaviomedeiros.c) corrects the problem of buffer.c
mentioned.
<http://savannah.nongnu.org/bugs/download.php?file_id=27860>

    _______________________________________________________

Reply to this item at:

  <http://savannah.nongnu.org/bugs/?38729>

_______________________________________________
  Message sent via/by Savannah
  http://savannah.nongnu.org/




reply via email to

[Prev in Thread] Current Thread [Next in Thread]