Check-in [3f5ef308fe]
Not logged in

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

Overview
Comment:Fix the web-browser user setting so that it actually works.
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA1: 3f5ef308feee511345c4dbbcf1713858e3c68e7a
User & Date: drh 2008-10-27 15:34:20.000
Context
2008-10-31
13:33
Take care that the root directory name does not have extra "/" characters. Ticket [9c378ed139]. check-in: 1d280a85aa user: drh tags: trunk
2008-10-27
15:34
Fix the web-browser user setting so that it actually works. check-in: 3f5ef308fe user: drh tags: trunk
2008-10-26
21:30
Remove the unused inherit-anon configuration attribute. Fix the automatic redirect that follows a login operation. Fix "config push user" on the server side. check-in: 0600b278c0 user: drh tags: trunk
Changes
Unified Diff Ignore Whitespace Patch
Changes to src/main.c.
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739

740
741
742
743
744
745
746
  }
  if( g.argc!=2 && g.argc!=3 ) usage("?REPOSITORY?");
  if( g.argc==2 ){
    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__)
    zBrowser = db_get("web-browser", "firefox");
#else
    zBrowser = db_get("web-browser", "open");
#endif
    zBrowserCmd = mprintf("%s http://localhost:%d/ &", zBrowser, iPort);
  }

  if( cgi_http_server(iPort, zBrowserCmd) ){
    fossil_fatal("unable to listen on TCP socket %d", iPort);
  }
  g.httpIn = stdin;
  g.httpOut = stdout;
  if( g.fHttpTrace ){
    fprintf(stderr, "====== SERVER pid %d =======\n", getpid());







<










>







722
723
724
725
726
727
728

729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
  }
  if( g.argc!=2 && g.argc!=3 ) usage("?REPOSITORY?");
  if( g.argc==2 ){
    db_must_be_within_tree();
  }else{
    db_open_repository(g.argv[2]);
  }

#ifndef __MINGW32__
  /* Unix implementation */
  if( g.argv[1][0]=='u' ){
#if !defined(__DARWIN__) && !defined(__APPLE__)
    zBrowser = db_get("web-browser", "firefox");
#else
    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;
  g.httpOut = stdout;
  if( g.fHttpTrace ){
    fprintf(stderr, "====== SERVER pid %d =======\n", getpid());
755
756
757
758
759
760
761

762
763
764
  process_one_web_page();
#else
  /* Win32 implementation */
  if( g.argv[1][0]=='u' ){
    zBrowser = db_get("web-browser", "start");
    zBrowserCmd = mprintf("%s http://127.0.0.1:%d/", zBrowser, iPort);
  }

  win32_http_server(iPort, zBrowserCmd);
#endif
}







>



755
756
757
758
759
760
761
762
763
764
765
  process_one_web_page();
#else
  /* Win32 implementation */
  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
}