~ubuntu-branches/ubuntu/lucid/postgresql-8.4/lucid-proposed

« back to all changes in this revision

Viewing changes to src/interfaces/libpq/fe-connect.c

  • Committer: Package Import Robot
  • Author(s): Martin Pitt
  • Date: 2012-12-10 15:53:42 UTC
  • mfrom: (1.3.9)
  • Revision ID: package-import@ubuntu.com-20121210155342-3scm68xcxel275jb
Tags: 8.4.15-0ubuntu10.04
* New upstream bug fix release: (LP: #1088393)
  - Fix multiple bugs associated with "CREATE INDEX CONCURRENTLY"
    Fix "CREATE INDEX CONCURRENTLY" to use in-place updates when
    changing the state of an index's pg_index row. This prevents race
    conditions that could cause concurrent sessions to miss updating
    the target index, thus resulting in corrupt concurrently-created
    indexes.
    Also, fix various other operations to ensure that they ignore
    invalid indexes resulting from a failed "CREATE INDEX CONCURRENTLY"
    command. The most important of these is "VACUUM", because an
    auto-vacuum could easily be launched on the table before corrective
    action can be taken to fix or remove the invalid index.
  - See HISTORY/changelog.gz for details about other bug fixes.

Show diffs side-by-side

added added

removed removed

Lines of Context:
790
790
connectDBStart(PGconn *conn)
791
791
{
792
792
        int                     portnum;
793
 
        char            portstr[128];
 
793
        char            portstr[MAXPGPATH];
794
794
        struct addrinfo *addrs = NULL;
795
795
        struct addrinfo hint;
796
796
        const char *node;
842
842
                node = NULL;
843
843
                hint.ai_family = AF_UNIX;
844
844
                UNIXSOCK_PATH(portstr, portnum, conn->pgunixsocket);
 
845
                if (strlen(portstr) >= UNIXSOCK_PATH_BUFLEN)
 
846
                {
 
847
                        appendPQExpBuffer(&conn->errorMessage,
 
848
                                                          libpq_gettext("Unix-domain socket path \"%s\" is too long (maximum %d bytes)\n"),
 
849
                                                                                        portstr,
 
850
                                                                                        (int) (UNIXSOCK_PATH_BUFLEN - 1));
 
851
                        conn->options_valid = false;
 
852
                        goto connect_errReturn;
 
853
                }
845
854
#else
846
855
                /* Without Unix sockets, default to localhost instead */
847
856
                node = "localhost";