Fossil SCM
Make sure the 'server' command checks for and processes the --files-urlenc option
Commit
eed3946bd92a499ed81c790e161d9e7c20ecd037
Parent
4a1188d56992f14…
6 files changed
+8
-1
+8
-1
+8
-1
+6
-1
+6
-1
+6
-1
+8
-1
| --- src/main.c | ||
| +++ src/main.c | ||
| @@ -1951,11 +1951,18 @@ | ||
| 1951 | 1951 | #if defined(_WIN32) |
| 1952 | 1952 | const char *zStopperFile; /* Name of file used to terminate server */ |
| 1953 | 1953 | zStopperFile = find_option("stopper", 0, 1); |
| 1954 | 1954 | #endif |
| 1955 | 1955 | |
| 1956 | - zFileGlob = find_option("files", 0, 1); | |
| 1956 | + zFileGlob = find_option("files-urlenc",0,1); | |
| 1957 | + if( zFileGlob ){ | |
| 1958 | + char *z = mprintf("%s", zFileGlob); | |
| 1959 | + dehttpize(z); | |
| 1960 | + zFileGlob = z; | |
| 1961 | + }else{ | |
| 1962 | + zFileGlob = find_option("files",0,1); | |
| 1963 | + } | |
| 1957 | 1964 | g.useLocalauth = find_option("localauth", 0, 0)!=0; |
| 1958 | 1965 | Th_InitTraceLog(); |
| 1959 | 1966 | zPort = find_option("port", "P", 1); |
| 1960 | 1967 | zNotFound = find_option("notfound", 0, 1); |
| 1961 | 1968 | zAltBase = find_option("baseurl", 0, 1); |
| 1962 | 1969 |
| --- src/main.c | |
| +++ src/main.c | |
| @@ -1951,11 +1951,18 @@ | |
| 1951 | #if defined(_WIN32) |
| 1952 | const char *zStopperFile; /* Name of file used to terminate server */ |
| 1953 | zStopperFile = find_option("stopper", 0, 1); |
| 1954 | #endif |
| 1955 | |
| 1956 | zFileGlob = find_option("files", 0, 1); |
| 1957 | g.useLocalauth = find_option("localauth", 0, 0)!=0; |
| 1958 | Th_InitTraceLog(); |
| 1959 | zPort = find_option("port", "P", 1); |
| 1960 | zNotFound = find_option("notfound", 0, 1); |
| 1961 | zAltBase = find_option("baseurl", 0, 1); |
| 1962 |
| --- src/main.c | |
| +++ src/main.c | |
| @@ -1951,11 +1951,18 @@ | |
| 1951 | #if defined(_WIN32) |
| 1952 | const char *zStopperFile; /* Name of file used to terminate server */ |
| 1953 | zStopperFile = find_option("stopper", 0, 1); |
| 1954 | #endif |
| 1955 | |
| 1956 | zFileGlob = find_option("files-urlenc",0,1); |
| 1957 | if( zFileGlob ){ |
| 1958 | char *z = mprintf("%s", zFileGlob); |
| 1959 | dehttpize(z); |
| 1960 | zFileGlob = z; |
| 1961 | }else{ |
| 1962 | zFileGlob = find_option("files",0,1); |
| 1963 | } |
| 1964 | g.useLocalauth = find_option("localauth", 0, 0)!=0; |
| 1965 | Th_InitTraceLog(); |
| 1966 | zPort = find_option("port", "P", 1); |
| 1967 | zNotFound = find_option("notfound", 0, 1); |
| 1968 | zAltBase = find_option("baseurl", 0, 1); |
| 1969 |
+8
-1
| --- src/main.c | ||
| +++ src/main.c | ||
| @@ -1951,11 +1951,18 @@ | ||
| 1951 | 1951 | #if defined(_WIN32) |
| 1952 | 1952 | const char *zStopperFile; /* Name of file used to terminate server */ |
| 1953 | 1953 | zStopperFile = find_option("stopper", 0, 1); |
| 1954 | 1954 | #endif |
| 1955 | 1955 | |
| 1956 | - zFileGlob = find_option("files", 0, 1); | |
| 1956 | + zFileGlob = find_option("files-urlenc",0,1); | |
| 1957 | + if( zFileGlob ){ | |
| 1958 | + char *z = mprintf("%s", zFileGlob); | |
| 1959 | + dehttpize(z); | |
| 1960 | + zFileGlob = z; | |
| 1961 | + }else{ | |
| 1962 | + zFileGlob = find_option("files",0,1); | |
| 1963 | + } | |
| 1957 | 1964 | g.useLocalauth = find_option("localauth", 0, 0)!=0; |
| 1958 | 1965 | Th_InitTraceLog(); |
| 1959 | 1966 | zPort = find_option("port", "P", 1); |
| 1960 | 1967 | zNotFound = find_option("notfound", 0, 1); |
| 1961 | 1968 | zAltBase = find_option("baseurl", 0, 1); |
| 1962 | 1969 |
| --- src/main.c | |
| +++ src/main.c | |
| @@ -1951,11 +1951,18 @@ | |
| 1951 | #if defined(_WIN32) |
| 1952 | const char *zStopperFile; /* Name of file used to terminate server */ |
| 1953 | zStopperFile = find_option("stopper", 0, 1); |
| 1954 | #endif |
| 1955 | |
| 1956 | zFileGlob = find_option("files", 0, 1); |
| 1957 | g.useLocalauth = find_option("localauth", 0, 0)!=0; |
| 1958 | Th_InitTraceLog(); |
| 1959 | zPort = find_option("port", "P", 1); |
| 1960 | zNotFound = find_option("notfound", 0, 1); |
| 1961 | zAltBase = find_option("baseurl", 0, 1); |
| 1962 |
| --- src/main.c | |
| +++ src/main.c | |
| @@ -1951,11 +1951,18 @@ | |
| 1951 | #if defined(_WIN32) |
| 1952 | const char *zStopperFile; /* Name of file used to terminate server */ |
| 1953 | zStopperFile = find_option("stopper", 0, 1); |
| 1954 | #endif |
| 1955 | |
| 1956 | zFileGlob = find_option("files-urlenc",0,1); |
| 1957 | if( zFileGlob ){ |
| 1958 | char *z = mprintf("%s", zFileGlob); |
| 1959 | dehttpize(z); |
| 1960 | zFileGlob = z; |
| 1961 | }else{ |
| 1962 | zFileGlob = find_option("files",0,1); |
| 1963 | } |
| 1964 | g.useLocalauth = find_option("localauth", 0, 0)!=0; |
| 1965 | Th_InitTraceLog(); |
| 1966 | zPort = find_option("port", "P", 1); |
| 1967 | zNotFound = find_option("notfound", 0, 1); |
| 1968 | zAltBase = find_option("baseurl", 0, 1); |
| 1969 |
+8
-1
| --- src/main.c | ||
| +++ src/main.c | ||
| @@ -1951,11 +1951,18 @@ | ||
| 1951 | 1951 | #if defined(_WIN32) |
| 1952 | 1952 | const char *zStopperFile; /* Name of file used to terminate server */ |
| 1953 | 1953 | zStopperFile = find_option("stopper", 0, 1); |
| 1954 | 1954 | #endif |
| 1955 | 1955 | |
| 1956 | - zFileGlob = find_option("files", 0, 1); | |
| 1956 | + zFileGlob = find_option("files-urlenc",0,1); | |
| 1957 | + if( zFileGlob ){ | |
| 1958 | + char *z = mprintf("%s", zFileGlob); | |
| 1959 | + dehttpize(z); | |
| 1960 | + zFileGlob = z; | |
| 1961 | + }else{ | |
| 1962 | + zFileGlob = find_option("files",0,1); | |
| 1963 | + } | |
| 1957 | 1964 | g.useLocalauth = find_option("localauth", 0, 0)!=0; |
| 1958 | 1965 | Th_InitTraceLog(); |
| 1959 | 1966 | zPort = find_option("port", "P", 1); |
| 1960 | 1967 | zNotFound = find_option("notfound", 0, 1); |
| 1961 | 1968 | zAltBase = find_option("baseurl", 0, 1); |
| 1962 | 1969 |
| --- src/main.c | |
| +++ src/main.c | |
| @@ -1951,11 +1951,18 @@ | |
| 1951 | #if defined(_WIN32) |
| 1952 | const char *zStopperFile; /* Name of file used to terminate server */ |
| 1953 | zStopperFile = find_option("stopper", 0, 1); |
| 1954 | #endif |
| 1955 | |
| 1956 | zFileGlob = find_option("files", 0, 1); |
| 1957 | g.useLocalauth = find_option("localauth", 0, 0)!=0; |
| 1958 | Th_InitTraceLog(); |
| 1959 | zPort = find_option("port", "P", 1); |
| 1960 | zNotFound = find_option("notfound", 0, 1); |
| 1961 | zAltBase = find_option("baseurl", 0, 1); |
| 1962 |
| --- src/main.c | |
| +++ src/main.c | |
| @@ -1951,11 +1951,18 @@ | |
| 1951 | #if defined(_WIN32) |
| 1952 | const char *zStopperFile; /* Name of file used to terminate server */ |
| 1953 | zStopperFile = find_option("stopper", 0, 1); |
| 1954 | #endif |
| 1955 | |
| 1956 | zFileGlob = find_option("files-urlenc",0,1); |
| 1957 | if( zFileGlob ){ |
| 1958 | char *z = mprintf("%s", zFileGlob); |
| 1959 | dehttpize(z); |
| 1960 | zFileGlob = z; |
| 1961 | }else{ |
| 1962 | zFileGlob = find_option("files",0,1); |
| 1963 | } |
| 1964 | g.useLocalauth = find_option("localauth", 0, 0)!=0; |
| 1965 | Th_InitTraceLog(); |
| 1966 | zPort = find_option("port", "P", 1); |
| 1967 | zNotFound = find_option("notfound", 0, 1); |
| 1968 | zAltBase = find_option("baseurl", 0, 1); |
| 1969 |
+6
-1
| --- src/winhttp.c | ||
| +++ src/winhttp.c | ||
| @@ -688,10 +688,15 @@ | ||
| 688 | 688 | } |
| 689 | 689 | /* Process service creation specific options. */ |
| 690 | 690 | if( !zDisplay ){ |
| 691 | 691 | zDisplay = zSvcName; |
| 692 | 692 | } |
| 693 | + /* Per MSDN, the password parameter cannot be NULL. Must use empty | |
| 694 | + ** string instead (i.e. in the call to CreateServiceW). */ | |
| 695 | + if( !zPassword ){ | |
| 696 | + zPassword = ""; | |
| 697 | + } | |
| 693 | 698 | if( zStart ){ |
| 694 | 699 | if( strncmp(zStart, "auto", strlen(zStart))==0 ){ |
| 695 | 700 | dwStartType = SERVICE_AUTO_START; |
| 696 | 701 | }else if( strncmp(zStart, "manual", strlen(zStart))==0 ){ |
| 697 | 702 | dwStartType = SERVICE_DEMAND_START; |
| @@ -736,11 +741,11 @@ | ||
| 736 | 741 | SERVICE_ERROR_NORMAL, /* Error control */ |
| 737 | 742 | fossil_utf8_to_unicode(blob_str(&binPath)), /* Binary path */ |
| 738 | 743 | NULL, /* Load ordering group */ |
| 739 | 744 | NULL, /* Tag value */ |
| 740 | 745 | NULL, /* Service dependencies */ |
| 741 | - fossil_utf8_to_unicode(zUsername), /* Service account */ | |
| 746 | + zUsername ? fossil_utf8_to_unicode(zUsername) : 0, /* Account */ | |
| 742 | 747 | fossil_utf8_to_unicode(zPassword) /* Account password */ |
| 743 | 748 | ); |
| 744 | 749 | if( !hSvc ) fossil_fatal(zErrFmt, zSvcName, win32_get_last_errmsg()); |
| 745 | 750 | /* Set the service description. */ |
| 746 | 751 | ChangeServiceConfig2W(hSvc, SERVICE_CONFIG_DESCRIPTION, &svcDescr); |
| 747 | 752 |
| --- src/winhttp.c | |
| +++ src/winhttp.c | |
| @@ -688,10 +688,15 @@ | |
| 688 | } |
| 689 | /* Process service creation specific options. */ |
| 690 | if( !zDisplay ){ |
| 691 | zDisplay = zSvcName; |
| 692 | } |
| 693 | if( zStart ){ |
| 694 | if( strncmp(zStart, "auto", strlen(zStart))==0 ){ |
| 695 | dwStartType = SERVICE_AUTO_START; |
| 696 | }else if( strncmp(zStart, "manual", strlen(zStart))==0 ){ |
| 697 | dwStartType = SERVICE_DEMAND_START; |
| @@ -736,11 +741,11 @@ | |
| 736 | SERVICE_ERROR_NORMAL, /* Error control */ |
| 737 | fossil_utf8_to_unicode(blob_str(&binPath)), /* Binary path */ |
| 738 | NULL, /* Load ordering group */ |
| 739 | NULL, /* Tag value */ |
| 740 | NULL, /* Service dependencies */ |
| 741 | fossil_utf8_to_unicode(zUsername), /* Service account */ |
| 742 | fossil_utf8_to_unicode(zPassword) /* Account password */ |
| 743 | ); |
| 744 | if( !hSvc ) fossil_fatal(zErrFmt, zSvcName, win32_get_last_errmsg()); |
| 745 | /* Set the service description. */ |
| 746 | ChangeServiceConfig2W(hSvc, SERVICE_CONFIG_DESCRIPTION, &svcDescr); |
| 747 |
| --- src/winhttp.c | |
| +++ src/winhttp.c | |
| @@ -688,10 +688,15 @@ | |
| 688 | } |
| 689 | /* Process service creation specific options. */ |
| 690 | if( !zDisplay ){ |
| 691 | zDisplay = zSvcName; |
| 692 | } |
| 693 | /* Per MSDN, the password parameter cannot be NULL. Must use empty |
| 694 | ** string instead (i.e. in the call to CreateServiceW). */ |
| 695 | if( !zPassword ){ |
| 696 | zPassword = ""; |
| 697 | } |
| 698 | if( zStart ){ |
| 699 | if( strncmp(zStart, "auto", strlen(zStart))==0 ){ |
| 700 | dwStartType = SERVICE_AUTO_START; |
| 701 | }else if( strncmp(zStart, "manual", strlen(zStart))==0 ){ |
| 702 | dwStartType = SERVICE_DEMAND_START; |
| @@ -736,11 +741,11 @@ | |
| 741 | SERVICE_ERROR_NORMAL, /* Error control */ |
| 742 | fossil_utf8_to_unicode(blob_str(&binPath)), /* Binary path */ |
| 743 | NULL, /* Load ordering group */ |
| 744 | NULL, /* Tag value */ |
| 745 | NULL, /* Service dependencies */ |
| 746 | zUsername ? fossil_utf8_to_unicode(zUsername) : 0, /* Account */ |
| 747 | fossil_utf8_to_unicode(zPassword) /* Account password */ |
| 748 | ); |
| 749 | if( !hSvc ) fossil_fatal(zErrFmt, zSvcName, win32_get_last_errmsg()); |
| 750 | /* Set the service description. */ |
| 751 | ChangeServiceConfig2W(hSvc, SERVICE_CONFIG_DESCRIPTION, &svcDescr); |
| 752 |
+6
-1
| --- src/winhttp.c | ||
| +++ src/winhttp.c | ||
| @@ -688,10 +688,15 @@ | ||
| 688 | 688 | } |
| 689 | 689 | /* Process service creation specific options. */ |
| 690 | 690 | if( !zDisplay ){ |
| 691 | 691 | zDisplay = zSvcName; |
| 692 | 692 | } |
| 693 | + /* Per MSDN, the password parameter cannot be NULL. Must use empty | |
| 694 | + ** string instead (i.e. in the call to CreateServiceW). */ | |
| 695 | + if( !zPassword ){ | |
| 696 | + zPassword = ""; | |
| 697 | + } | |
| 693 | 698 | if( zStart ){ |
| 694 | 699 | if( strncmp(zStart, "auto", strlen(zStart))==0 ){ |
| 695 | 700 | dwStartType = SERVICE_AUTO_START; |
| 696 | 701 | }else if( strncmp(zStart, "manual", strlen(zStart))==0 ){ |
| 697 | 702 | dwStartType = SERVICE_DEMAND_START; |
| @@ -736,11 +741,11 @@ | ||
| 736 | 741 | SERVICE_ERROR_NORMAL, /* Error control */ |
| 737 | 742 | fossil_utf8_to_unicode(blob_str(&binPath)), /* Binary path */ |
| 738 | 743 | NULL, /* Load ordering group */ |
| 739 | 744 | NULL, /* Tag value */ |
| 740 | 745 | NULL, /* Service dependencies */ |
| 741 | - fossil_utf8_to_unicode(zUsername), /* Service account */ | |
| 746 | + zUsername ? fossil_utf8_to_unicode(zUsername) : 0, /* Account */ | |
| 742 | 747 | fossil_utf8_to_unicode(zPassword) /* Account password */ |
| 743 | 748 | ); |
| 744 | 749 | if( !hSvc ) fossil_fatal(zErrFmt, zSvcName, win32_get_last_errmsg()); |
| 745 | 750 | /* Set the service description. */ |
| 746 | 751 | ChangeServiceConfig2W(hSvc, SERVICE_CONFIG_DESCRIPTION, &svcDescr); |
| 747 | 752 |
| --- src/winhttp.c | |
| +++ src/winhttp.c | |
| @@ -688,10 +688,15 @@ | |
| 688 | } |
| 689 | /* Process service creation specific options. */ |
| 690 | if( !zDisplay ){ |
| 691 | zDisplay = zSvcName; |
| 692 | } |
| 693 | if( zStart ){ |
| 694 | if( strncmp(zStart, "auto", strlen(zStart))==0 ){ |
| 695 | dwStartType = SERVICE_AUTO_START; |
| 696 | }else if( strncmp(zStart, "manual", strlen(zStart))==0 ){ |
| 697 | dwStartType = SERVICE_DEMAND_START; |
| @@ -736,11 +741,11 @@ | |
| 736 | SERVICE_ERROR_NORMAL, /* Error control */ |
| 737 | fossil_utf8_to_unicode(blob_str(&binPath)), /* Binary path */ |
| 738 | NULL, /* Load ordering group */ |
| 739 | NULL, /* Tag value */ |
| 740 | NULL, /* Service dependencies */ |
| 741 | fossil_utf8_to_unicode(zUsername), /* Service account */ |
| 742 | fossil_utf8_to_unicode(zPassword) /* Account password */ |
| 743 | ); |
| 744 | if( !hSvc ) fossil_fatal(zErrFmt, zSvcName, win32_get_last_errmsg()); |
| 745 | /* Set the service description. */ |
| 746 | ChangeServiceConfig2W(hSvc, SERVICE_CONFIG_DESCRIPTION, &svcDescr); |
| 747 |
| --- src/winhttp.c | |
| +++ src/winhttp.c | |
| @@ -688,10 +688,15 @@ | |
| 688 | } |
| 689 | /* Process service creation specific options. */ |
| 690 | if( !zDisplay ){ |
| 691 | zDisplay = zSvcName; |
| 692 | } |
| 693 | /* Per MSDN, the password parameter cannot be NULL. Must use empty |
| 694 | ** string instead (i.e. in the call to CreateServiceW). */ |
| 695 | if( !zPassword ){ |
| 696 | zPassword = ""; |
| 697 | } |
| 698 | if( zStart ){ |
| 699 | if( strncmp(zStart, "auto", strlen(zStart))==0 ){ |
| 700 | dwStartType = SERVICE_AUTO_START; |
| 701 | }else if( strncmp(zStart, "manual", strlen(zStart))==0 ){ |
| 702 | dwStartType = SERVICE_DEMAND_START; |
| @@ -736,11 +741,11 @@ | |
| 741 | SERVICE_ERROR_NORMAL, /* Error control */ |
| 742 | fossil_utf8_to_unicode(blob_str(&binPath)), /* Binary path */ |
| 743 | NULL, /* Load ordering group */ |
| 744 | NULL, /* Tag value */ |
| 745 | NULL, /* Service dependencies */ |
| 746 | zUsername ? fossil_utf8_to_unicode(zUsername) : 0, /* Account */ |
| 747 | fossil_utf8_to_unicode(zPassword) /* Account password */ |
| 748 | ); |
| 749 | if( !hSvc ) fossil_fatal(zErrFmt, zSvcName, win32_get_last_errmsg()); |
| 750 | /* Set the service description. */ |
| 751 | ChangeServiceConfig2W(hSvc, SERVICE_CONFIG_DESCRIPTION, &svcDescr); |
| 752 |
+6
-1
| --- src/winhttp.c | ||
| +++ src/winhttp.c | ||
| @@ -688,10 +688,15 @@ | ||
| 688 | 688 | } |
| 689 | 689 | /* Process service creation specific options. */ |
| 690 | 690 | if( !zDisplay ){ |
| 691 | 691 | zDisplay = zSvcName; |
| 692 | 692 | } |
| 693 | + /* Per MSDN, the password parameter cannot be NULL. Must use empty | |
| 694 | + ** string instead (i.e. in the call to CreateServiceW). */ | |
| 695 | + if( !zPassword ){ | |
| 696 | + zPassword = ""; | |
| 697 | + } | |
| 693 | 698 | if( zStart ){ |
| 694 | 699 | if( strncmp(zStart, "auto", strlen(zStart))==0 ){ |
| 695 | 700 | dwStartType = SERVICE_AUTO_START; |
| 696 | 701 | }else if( strncmp(zStart, "manual", strlen(zStart))==0 ){ |
| 697 | 702 | dwStartType = SERVICE_DEMAND_START; |
| @@ -736,11 +741,11 @@ | ||
| 736 | 741 | SERVICE_ERROR_NORMAL, /* Error control */ |
| 737 | 742 | fossil_utf8_to_unicode(blob_str(&binPath)), /* Binary path */ |
| 738 | 743 | NULL, /* Load ordering group */ |
| 739 | 744 | NULL, /* Tag value */ |
| 740 | 745 | NULL, /* Service dependencies */ |
| 741 | - fossil_utf8_to_unicode(zUsername), /* Service account */ | |
| 746 | + zUsername ? fossil_utf8_to_unicode(zUsername) : 0, /* Account */ | |
| 742 | 747 | fossil_utf8_to_unicode(zPassword) /* Account password */ |
| 743 | 748 | ); |
| 744 | 749 | if( !hSvc ) fossil_fatal(zErrFmt, zSvcName, win32_get_last_errmsg()); |
| 745 | 750 | /* Set the service description. */ |
| 746 | 751 | ChangeServiceConfig2W(hSvc, SERVICE_CONFIG_DESCRIPTION, &svcDescr); |
| 747 | 752 |
| --- src/winhttp.c | |
| +++ src/winhttp.c | |
| @@ -688,10 +688,15 @@ | |
| 688 | } |
| 689 | /* Process service creation specific options. */ |
| 690 | if( !zDisplay ){ |
| 691 | zDisplay = zSvcName; |
| 692 | } |
| 693 | if( zStart ){ |
| 694 | if( strncmp(zStart, "auto", strlen(zStart))==0 ){ |
| 695 | dwStartType = SERVICE_AUTO_START; |
| 696 | }else if( strncmp(zStart, "manual", strlen(zStart))==0 ){ |
| 697 | dwStartType = SERVICE_DEMAND_START; |
| @@ -736,11 +741,11 @@ | |
| 736 | SERVICE_ERROR_NORMAL, /* Error control */ |
| 737 | fossil_utf8_to_unicode(blob_str(&binPath)), /* Binary path */ |
| 738 | NULL, /* Load ordering group */ |
| 739 | NULL, /* Tag value */ |
| 740 | NULL, /* Service dependencies */ |
| 741 | fossil_utf8_to_unicode(zUsername), /* Service account */ |
| 742 | fossil_utf8_to_unicode(zPassword) /* Account password */ |
| 743 | ); |
| 744 | if( !hSvc ) fossil_fatal(zErrFmt, zSvcName, win32_get_last_errmsg()); |
| 745 | /* Set the service description. */ |
| 746 | ChangeServiceConfig2W(hSvc, SERVICE_CONFIG_DESCRIPTION, &svcDescr); |
| 747 |
| --- src/winhttp.c | |
| +++ src/winhttp.c | |
| @@ -688,10 +688,15 @@ | |
| 688 | } |
| 689 | /* Process service creation specific options. */ |
| 690 | if( !zDisplay ){ |
| 691 | zDisplay = zSvcName; |
| 692 | } |
| 693 | /* Per MSDN, the password parameter cannot be NULL. Must use empty |
| 694 | ** string instead (i.e. in the call to CreateServiceW). */ |
| 695 | if( !zPassword ){ |
| 696 | zPassword = ""; |
| 697 | } |
| 698 | if( zStart ){ |
| 699 | if( strncmp(zStart, "auto", strlen(zStart))==0 ){ |
| 700 | dwStartType = SERVICE_AUTO_START; |
| 701 | }else if( strncmp(zStart, "manual", strlen(zStart))==0 ){ |
| 702 | dwStartType = SERVICE_DEMAND_START; |
| @@ -736,11 +741,11 @@ | |
| 741 | SERVICE_ERROR_NORMAL, /* Error control */ |
| 742 | fossil_utf8_to_unicode(blob_str(&binPath)), /* Binary path */ |
| 743 | NULL, /* Load ordering group */ |
| 744 | NULL, /* Tag value */ |
| 745 | NULL, /* Service dependencies */ |
| 746 | zUsername ? fossil_utf8_to_unicode(zUsername) : 0, /* Account */ |
| 747 | fossil_utf8_to_unicode(zPassword) /* Account password */ |
| 748 | ); |
| 749 | if( !hSvc ) fossil_fatal(zErrFmt, zSvcName, win32_get_last_errmsg()); |
| 750 | /* Set the service description. */ |
| 751 | ChangeServiceConfig2W(hSvc, SERVICE_CONFIG_DESCRIPTION, &svcDescr); |
| 752 |