Fossil

Check-in [aee65577]
Login

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:Fix the socket_open() routine so that it returns a non-zero error code if it fails to connect.
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA1:aee65577cbaab3932c03cc0558331994d7211025
User & Date: drh 2015-02-08 22:26:18
Context
2015-02-09
04:10
On timelines, to show the "selected" entry, give the row some vertical space between the previous and following rows, a yellow background, a gray border, and a shadow-box (all adjustable via CSS). For the c=TIME "circa" query parameter, highlight the nearest entry. check-in: f4e299d0 user: drh tags: trunk
2015-02-08
22:26
Fix the socket_open() routine so that it returns a non-zero error code if it fails to connect. check-in: aee65577 user: drh tags: trunk
21:47
Add the --ifneeded option to the "fossil rebuild" command. Changed the --no-index option to --noindex for consistency. Updated the help screen for "fossil rebuild" so that options are in sorted order. check-in: 7a91ee99 user: drh tags: trunk
Changes
Hide Diffs Unified Diffs Ignore Whitespace Patch

Changes to src/http_socket.c.

171
172
173
174
175
176
177

178
179
180
181
182
183
184
    }
    g.zIpAddr = mprintf("%s", zRemote);
    break;
  }
  if( p==0 ){
    socket_set_errmsg("cannot connect to host %s:%d", pUrlData->name,
                      pUrlData->port);

  }
#if !defined(_WIN32)
  signal(SIGPIPE, SIG_IGN);
#endif
end_socket_open:
  if( rc && iSocket>=0 ) socket_close();
  if( ai ) freeaddrinfo(ai);







>







171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
    }
    g.zIpAddr = mprintf("%s", zRemote);
    break;
  }
  if( p==0 ){
    socket_set_errmsg("cannot connect to host %s:%d", pUrlData->name,
                      pUrlData->port);
    rc = 1;
  }
#if !defined(_WIN32)
  signal(SIGPIPE, SIG_IGN);
#endif
end_socket_open:
  if( rc && iSocket>=0 ) socket_close();
  if( ai ) freeaddrinfo(ai);