Ignore:
Timestamp:
Jun 30, 2009, 5:18:33 PM (16 years ago)
Author:
Silvan Scherrer
Message:

fix swat, so that it works even when samba is not in x:\samba

Location:
branches/samba-3.3.x/source/web
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • branches/samba-3.3.x/source/web/startstop.c

    r246 r289  
    2525#include "process.h"
    2626#define SWAT_HELPER(WHAT, WHO) \
    27         asprintf(&binfile, "%s/swathelp.cmd", get_dyn_SWATDIR()); \
     27        asprintf(&binfile, "%s/swathelp.cmd", getcwd(NULL, _MAX_PATH)); \
    2828        int rc; \
    2929        rc=spawnl(P_NOWAIT, binfile, binfile, #WHAT, #WHO, NULL);
  • branches/samba-3.3.x/source/web/swat.c

    r206 r289  
    175175        }
    176176        printf("Content-type: text/html\r\n\r\n");
    177 
     177DEBUG(0,("test2\n"));
    178178        if (!include_html("include/header.html")) {
    179179                printf("<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 3.2//EN\">\n");
     
    14361436        load_printers();
    14371437
     1438#ifndef __OS2__
    14381439        cgi_setup(get_dyn_SWATDIR(), !demo_mode);
     1440#else
     1441
     1442#if 0
     1443        debug_set_logfile("swat.log"); // this produces a logfile in the dir where swat.exe is located.
     1444#endif
     1445
     1446        fstring path;
     1447        fstrcpy(path, getcwd(NULL, _MAX_PATH));
     1448        fstrcat(path, "/swat");
     1449        cgi_setup(path, !demo_mode);
     1450#endif
    14391451
    14401452        print_header();
Note: See TracChangeset for help on using the changeset viewer.