Diff
Not logged in

Differences From:

File src/main.c part of check-in [31e94c0a04] - Get "configuration push" working. Fix bugs in concealed-field processing of tickets. by drh on 2008-10-25 20:43:28. [view]

To:

File src/main.c part of check-in [3f5ef308fe] - Fix the web-browser user setting so that it actually works. by drh on 2008-10-27 15:34:20. [view]

@@ -725,9 +725,8 @@
     db_must_be_within_tree();
   }else{
     db_open_repository(g.argv[2]);
   }
-  db_close();
 #ifndef __MINGW32__
   /* Unix implementation */
   if( g.argv[1][0]=='u' ){
 #if !defined(__DARWIN__) && !defined(__APPLE__)
@@ -736,8 +735,9 @@
     zBrowser = db_get("web-browser", "open");
 #endif
     zBrowserCmd = mprintf("%s http://localhost:%d/ &", zBrowser, iPort);
   }
+  db_close();
   if( cgi_http_server(iPort, zBrowserCmd) ){
     fossil_fatal("unable to listen on TCP socket %d", iPort);
   }
   g.httpIn = stdin;
@@ -758,7 +758,8 @@
   if( g.argv[1][0]=='u' ){
     zBrowser = db_get("web-browser", "start");
     zBrowserCmd = mprintf("%s http://127.0.0.1:%d/", zBrowser, iPort);
   }
+  db_close();
   win32_http_server(iPort, zBrowserCmd);
 #endif
 }