pastebin - collaborative debugging tool
nrubsig.kpaste.net RSS


Win32 32bit build fixes 2024-02-01
Posted by Anonymous on Thu 1st Feb 2024 15:02
raw | new post

  1. diff --git a/build.vc19/libtirpc/libtirpc.vcxproj b/build.vc19/libtirpc/libtirpc.vcxproj
  2. index 37bc712..7c62f21 100644
  3. --- a/build.vc19/libtirpc/libtirpc.vcxproj
  4. +++ b/build.vc19/libtirpc/libtirpc.vcxproj
  5. @@ -108,7 +108,7 @@
  6.        </PrecompiledHeader>
  7.        <WarningLevel>Level3</WarningLevel>
  8.        <Optimization>Disabled</Optimization>
  9. -      <PreprocessorDefinitions>FD_SETSIZE=1024;INET6;NO_CB_4_KRB5P;PORTMAP;_WINSOCK_DEPRECATED_NO_WARNINGS;_DEBUG;_WINDOWS;_USRDLL;LIBTIRPC_EXPORTS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
  10. +      <PreprocessorDefinitions>FD_SETSIZE=1024;INET6;NO_CB_4_KRB5P;PORTMAP;_WINSOCK_DEPRECATED_NO_WARNINGS;WIN32;UNICODE;_UNICODE;_DEBUG;_WINDOWS;_USRDLL;LIBTIRPC_EXPORTS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
  11.        <AdditionalIncludeDirectories>..\..\libtirpc\tirpc;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
  12.        <LanguageStandard_C>stdc17</LanguageStandard_C>
  13.        <RuntimeLibrary>MultiThreadedDebug</RuntimeLibrary>
  14. @@ -155,7 +155,7 @@
  15.        <Optimization>MaxSpeed</Optimization>
  16.        <FunctionLevelLinking>true</FunctionLevelLinking>
  17.        <IntrinsicFunctions>true</IntrinsicFunctions>
  18. -      <PreprocessorDefinitions>FD_SETSIZE=1024;INET6;NO_CB_4_KRB5P;PORTMAP;_WINSOCK_DEPRECATED_NO_WARNINGS;NDEBUG;_WINDOWS;_USRDLL;LIBTIRPC_EXPORTS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
  19. +      <PreprocessorDefinitions>FD_SETSIZE=1024;INET6;NO_CB_4_KRB5P;PORTMAP;_WINSOCK_DEPRECATED_NO_WARNINGS;WIN32;UNICODE;_UNICODE;NDEBUG;_WINDOWS;_USRDLL;LIBTIRPC_EXPORTS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
  20.        <AdditionalIncludeDirectories>..\..\libtirpc\tirpc;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
  21.        <LanguageStandard_C>stdc17</LanguageStandard_C>
  22.        <RuntimeLibrary>MultiThreaded</RuntimeLibrary>
  23. diff --git a/build.vc19/nfs41_np/nfs41_np.vcxproj b/build.vc19/nfs41_np/nfs41_np.vcxproj
  24. index 3efe8f6..822a849 100644
  25. --- a/build.vc19/nfs41_np/nfs41_np.vcxproj
  26. +++ b/build.vc19/nfs41_np/nfs41_np.vcxproj
  27. @@ -104,7 +104,7 @@
  28.        </PrecompiledHeader>
  29.        <WarningLevel>Level3</WarningLevel>
  30.        <Optimization>Disabled</Optimization>
  31. -      <PreprocessorDefinitions>_DEBUG;_WINDOWS;_USRDLL;NFS41_NP_EXPORTS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
  32. +      <PreprocessorDefinitions>WIN32;UNICODE;_UNICODE;_DEBUG;_WINDOWS;_USRDLL;NFS41_NP_EXPORTS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
  33.        <AdditionalIncludeDirectories>..\..\sys;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
  34.        <LanguageStandard_C>stdc17</LanguageStandard_C>
  35.        <RuntimeLibrary>MultiThreadedDebug</RuntimeLibrary>
  36. @@ -144,7 +144,7 @@
  37.        <Optimization>MaxSpeed</Optimization>
  38.        <FunctionLevelLinking>true</FunctionLevelLinking>
  39.        <IntrinsicFunctions>true</IntrinsicFunctions>
  40. -      <PreprocessorDefinitions>NDEBUG;_WINDOWS;_USRDLL;NFS41_NP_EXPORTS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
  41. +      <PreprocessorDefinitions>WIN32;UNICODE;_UNICODE;NDEBUG;_WINDOWS;_USRDLL;NFS41_NP_EXPORTS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
  42.        <AdditionalIncludeDirectories>..\..\sys;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
  43.        <LanguageStandard_C>stdc17</LanguageStandard_C>
  44.        <RuntimeLibrary>MultiThreaded</RuntimeLibrary>
  45. diff --git a/build.vc19/nfs_install/nfs_install.vcxproj b/build.vc19/nfs_install/nfs_install.vcxproj
  46. index 898ba94..7f222d1 100644
  47. --- a/build.vc19/nfs_install/nfs_install.vcxproj
  48. +++ b/build.vc19/nfs_install/nfs_install.vcxproj
  49. @@ -103,7 +103,7 @@
  50.        </PrecompiledHeader>
  51.        <WarningLevel>Level3</WarningLevel>
  52.        <Optimization>Disabled</Optimization>
  53. -      <PreprocessorDefinitions>_DEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
  54. +      <PreprocessorDefinitions>WIN32;UNICODE;_UNICODE;_DEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
  55.        <AdditionalIncludeDirectories>..\..\sys;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
  56.        <LanguageStandard_C>stdc17</LanguageStandard_C>
  57.        <RuntimeLibrary>MultiThreadedDebug</RuntimeLibrary>
  58. @@ -141,7 +141,7 @@
  59.        <Optimization>MaxSpeed</Optimization>
  60.        <FunctionLevelLinking>true</FunctionLevelLinking>
  61.        <IntrinsicFunctions>true</IntrinsicFunctions>
  62. -      <PreprocessorDefinitions>NDEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
  63. +      <PreprocessorDefinitions>WIN32;UNICODE;_UNICODE;NDEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
  64.        <AdditionalIncludeDirectories>..\..\sys;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
  65.        <LanguageStandard_C>stdc17</LanguageStandard_C>
  66.        <RuntimeLibrary>MultiThreaded</RuntimeLibrary>
  67. diff --git a/build.vc19/nfs_mount/nfs_mount.vcxproj b/build.vc19/nfs_mount/nfs_mount.vcxproj
  68. index ea482e2..8d250cb 100644
  69. --- a/build.vc19/nfs_mount/nfs_mount.vcxproj
  70. +++ b/build.vc19/nfs_mount/nfs_mount.vcxproj
  71. @@ -104,7 +104,7 @@
  72.        </PrecompiledHeader>
  73.        <WarningLevel>Level3</WarningLevel>
  74.        <Optimization>Disabled</Optimization>
  75. -      <PreprocessorDefinitions>_DEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
  76. +      <PreprocessorDefinitions>WIN32;UNICODE;_UNICODE;_DEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
  77.        <AdditionalIncludeDirectories>..\..\sys;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
  78.        <LanguageStandard_C>stdc17</LanguageStandard_C>
  79.        <RuntimeLibrary>MultiThreadedDebug</RuntimeLibrary>
  80. @@ -144,7 +144,7 @@
  81.        <Optimization>MaxSpeed</Optimization>
  82.        <FunctionLevelLinking>true</FunctionLevelLinking>
  83.        <IntrinsicFunctions>true</IntrinsicFunctions>
  84. -      <PreprocessorDefinitions>NDEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
  85. +      <PreprocessorDefinitions>WIN32;UNICODE;_UNICODE;NDEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
  86.        <AdditionalIncludeDirectories>..\..\sys;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
  87.        <LanguageStandard_C>stdc17</LanguageStandard_C>
  88.        <RuntimeLibrary>MultiThreaded</RuntimeLibrary>
  89. diff --git a/build.vc19/nfsd/nfsd.vcxproj b/build.vc19/nfsd/nfsd.vcxproj
  90. index d506140..6cf1cf2 100644
  91. --- a/build.vc19/nfsd/nfsd.vcxproj
  92. +++ b/build.vc19/nfsd/nfsd.vcxproj
  93. @@ -107,7 +107,7 @@
  94.        </PrecompiledHeader>
  95.        <WarningLevel>Level3</WarningLevel>
  96.        <Optimization>Disabled</Optimization>
  97. -      <PreprocessorDefinitions>WIN32_LEAN_AND_MEAN;FD_SETSIZE=1024;INET6;NO_CB_4_KRB5P;STANDALONE_NFSD;_CRT_SECURE_NO_WARNINGS;_WINSOCK_DEPRECATED_NO_WARNINGS;_DEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
  98. +      <PreprocessorDefinitions>WIN32_LEAN_AND_MEAN;FD_SETSIZE=1024;INET6;NO_CB_4_KRB5P;STANDALONE_NFSD;_CRT_SECURE_NO_WARNINGS;_WINSOCK_DEPRECATED_NO_WARNINGS;WIN32;UNICODE;_UNICODE;_DEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
  99.        <AdditionalIncludeDirectories>..\..\libtirpc\tirpc;..\..\sys;..\..\dll;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
  100.        <LanguageStandard_C>stdc17</LanguageStandard_C>
  101.        <RuntimeLibrary>MultiThreadedDebug</RuntimeLibrary>
  102. @@ -152,7 +152,7 @@
  103.        <Optimization>MaxSpeed</Optimization>
  104.        <FunctionLevelLinking>true</FunctionLevelLinking>
  105.        <IntrinsicFunctions>true</IntrinsicFunctions>
  106. -      <PreprocessorDefinitions>WIN32_LEAN_AND_MEAN;FD_SETSIZE=1024;INET6;NO_CB_4_KRB5P;_CRT_SECURE_NO_WARNINGS;_WINSOCK_DEPRECATED_NO_WARNINGS;NDEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
  107. +      <PreprocessorDefinitions>WIN32_LEAN_AND_MEAN;FD_SETSIZE=1024;INET6;NO_CB_4_KRB5P;_CRT_SECURE_NO_WARNINGS;_WINSOCK_DEPRECATED_NO_WARNINGS;WIN32;UNICODE;_UNICODE;NDEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
  108.        <AdditionalIncludeDirectories>..\..\libtirpc\tirpc;..\..\sys;..\..\dll;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
  109.        <LanguageStandard_C>stdc17</LanguageStandard_C>
  110.        <RuntimeLibrary>MultiThreaded</RuntimeLibrary>
  111. diff --git a/daemon/acl.c b/daemon/acl.c
  112. index 583f7c6..a9e7e46 100644
  113. --- a/daemon/acl.c
  114. +++ b/daemon/acl.c
  115. @@ -492,7 +492,7 @@ static int map_nfs4ace_who(PSID sid, PSID owner_sid, PSID group_sid, char *who_o
  116.              return ERROR_SUCCESS;
  117.      }
  118.  
  119. -    status = LookupAccountSid(NULL, sid, who, &size, tmp_buf,
  120. +    status = LookupAccountSidA(NULL, sid, who, &size, tmp_buf,
  121.          &tmp_size, &sid_type);
  122.      dprintf(ACLLVL, "map_nfs4ace_who: LookupAccountSid returned %d GetLastError "
  123.              "%d name len %d domain len %d\n", status, GetLastError(),
  124. @@ -510,7 +510,7 @@ static int map_nfs4ace_who(PSID sid, PSID owner_sid, PSID group_sid, char *who_o
  125.      tmp_buf = malloc(tmp_size);
  126.      if (tmp_buf == NULL)
  127.          goto out_free_who;
  128. -    status = LookupAccountSid(NULL, sid, who, &size, tmp_buf,
  129. +    status = LookupAccountSidA(NULL, sid, who, &size, tmp_buf,
  130.                                  &tmp_size, &sid_type);
  131.      free(tmp_buf);
  132.      if (!status) {
  133. diff --git a/daemon/delegation.c b/daemon/delegation.c
  134. index e26c2af..bd04d68 100644
  135. --- a/daemon/delegation.c
  136. +++ b/daemon/delegation.c
  137. @@ -279,7 +279,7 @@ static int delegation_return(
  138.          uint32_t length;
  139.          dprintf(1, "delegation_return: making a downcall for srv_open=%x\n",
  140.              deleg->srv_open);
  141. -        pipe = CreateFile(NFS41_USER_DEVICE_NAME_A, GENERIC_READ|GENERIC_WRITE,
  142. +        pipe = CreateFileA(NFS41_USER_DEVICE_NAME_A, GENERIC_READ|GENERIC_WRITE,
  143.                  FILE_SHARE_READ|FILE_SHARE_WRITE, NULL, OPEN_EXISTING, 0, NULL);
  144.          if (pipe == INVALID_HANDLE_VALUE) {
  145.              eprintf("delegation_return: Unable to open downcall pipe %d\n",
  146. diff --git a/daemon/ea.c b/daemon/ea.c
  147. index baeb43a..77523e4 100644
  148. --- a/daemon/ea.c
  149. +++ b/daemon/ea.c
  150. @@ -605,7 +605,7 @@ static int handle_getexattr(void *daemon_context, nfs41_upcall *upcall)
  151.          }
  152.  
  153.          ea->EaNameLength = query->EaNameLength;
  154. -        StringCchCopy(ea->EaName, (size_t)ea->EaNameLength + 1, query->EaName);
  155. +        StringCchCopyA(ea->EaName, (size_t)ea->EaNameLength + 1, query->EaName);
  156.          ea->Flags = 0;
  157.  
  158.          /* read the value from file */
  159. diff --git a/daemon/idmap.c b/daemon/idmap.c
  160. index 169de15..f727b8b 100644
  161. --- a/daemon/idmap.c
  162. +++ b/daemon/idmap.c
  163. @@ -607,7 +607,7 @@ static int idmap_query_attrs(
  164.          goto out;
  165.  
  166.      /* send the ldap query */
  167. -    status = ldap_search_st(context->ldap, config->base,
  168. +    status = ldap_search_stA(context->ldap, config->base,
  169.          LDAP_SCOPE_SUBTREE, filter, NULL, 0, NULL, &res);
  170.      if (status) {
  171.          eprintf("ldap search for '%s' failed with %d: %s\n",
  172. @@ -628,7 +628,7 @@ static int idmap_query_attrs(
  173.      /* fetch the attributes */
  174.      for (i = 0; i < len; i++) {
  175.          if (ATTR_ISSET(attributes, i)) {
  176. -            values[i] = ldap_get_values(context->ldap,
  177. +            values[i] = ldap_get_valuesA(context->ldap,
  178.                  entry, config->attributes[i]);
  179.  
  180.              /* fail if required attributes are missing */
  181. @@ -801,7 +801,7 @@ static int idmap_lookup_user(
  182.      }
  183.  out_free_values:
  184.      for (i = 0; i < NUM_ATTRIBUTES; i++)
  185. -        ldap_value_free(values[i]);
  186. +        ldap_value_freeA(values[i]);
  187.  out:
  188.      return status;
  189.  }
  190. @@ -902,7 +902,7 @@ static int idmap_lookup_group(
  191.      }
  192.  out_free_values:
  193.      for (i = 0; i < NUM_ATTRIBUTES; i++)
  194. -        ldap_value_free(values[i]);
  195. +        ldap_value_freeA(values[i]);
  196.  out:
  197.      return status;
  198.  }
  199. diff --git a/daemon/nfs41_daemon.c b/daemon/nfs41_daemon.c
  200. index 9a06c44..82c337f 100644
  201. --- a/daemon/nfs41_daemon.c
  202. +++ b/daemon/nfs41_daemon.c
  203. @@ -100,7 +100,7 @@ static unsigned int WINAPI thread_main(void *args)
  204.      DWORD inbuf_len = UPCALL_BUF_SIZE, outbuf_len;
  205.      nfs41_upcall upcall;
  206.  
  207. -    pipe = CreateFile(NFS41_USER_DEVICE_NAME_A, GENERIC_READ | GENERIC_WRITE,
  208. +    pipe = CreateFileA(NFS41_USER_DEVICE_NAME_A, GENERIC_READ | GENERIC_WRITE,
  209.          FILE_SHARE_READ | FILE_SHARE_WRITE, NULL, OPEN_EXISTING,
  210.          0, NULL);
  211.      if (pipe == INVALID_HANDLE_VALUE)
  212. @@ -313,7 +313,7 @@ static bool_t parse_cmdlineargs(int argc, TCHAR *argv[], nfsd_args *out)
  213.                  }
  214.              }
  215.              else
  216. -                fprintf(stderr, "Unrecognized option '%s', disregarding.\n", argv[i]);
  217. +                fprintf(stderr, "Unrecognized option '%S', disregarding.\n", argv[i]);
  218.          }
  219.      }
  220.  
  221. @@ -339,7 +339,7 @@ static void print_getaddrinfo(struct addrinfo *ptr)
  222.              inet_ntoa(((struct sockaddr_in *)ptr->ai_addr)->sin_addr));
  223.          break;
  224.      case AF_INET6:
  225. -        if (WSAAddressToString((LPSOCKADDR)ptr->ai_addr, (DWORD)ptr->ai_addrlen,
  226. +        if (WSAAddressToStringA((LPSOCKADDR)ptr->ai_addr, (DWORD)ptr->ai_addrlen,
  227.                  NULL, ipstringbuffer, &ipbufferlength))
  228.              dprintf(1, "WSAAddressToString failed with %u\n", WSAGetLastError());
  229.          else    
  230. @@ -561,7 +561,7 @@ VOID ServiceStart(DWORD argc, LPTSTR *argv)
  231.      NFS41D_VERSION = GetTickCount();
  232.      dprintf(1, "NFS41 Daemon starting: version %d\n", NFS41D_VERSION);
  233.  
  234. -    pipe = CreateFile(NFS41_USER_DEVICE_NAME_A, GENERIC_READ | GENERIC_WRITE,
  235. +    pipe = CreateFileA(NFS41_USER_DEVICE_NAME_A, GENERIC_READ | GENERIC_WRITE,
  236.          FILE_SHARE_READ | FILE_SHARE_WRITE, NULL, OPEN_EXISTING,
  237.          0, NULL);
  238.      if (pipe == INVALID_HANDLE_VALUE)
  239. diff --git a/daemon/nfs41_server.c b/daemon/nfs41_server.c
  240. index 3a09935..982179e 100644
  241. --- a/daemon/nfs41_server.c
  242. +++ b/daemon/nfs41_server.c
  243. @@ -279,7 +279,7 @@ int nfs41_server_resolve(
  244.  {
  245.      int status = ERROR_BAD_NET_NAME;
  246.      char service[16];
  247. -    struct addrinfoexA hints = { 0 }, *res, *info;
  248. +    ADDRINFOEXA hints = { 0 }, *res, *info;
  249.      struct netconfig *nconf;
  250.      struct netbuf addr;
  251.      char *netid, *uaddr;
  252. @@ -368,6 +368,13 @@ retry_getaddrinfoex:
  253.              break;
  254.          }
  255.      }
  256. +/*
  257. + * BUG: WS2tcpip.h somenow mapps FreeAddrInfoExA() to use the wide-char version
  258. + */
  259. +#define WINDOWS_WS2TCPIP_H_BUG 1
  260. +#ifdef WINDOWS_WS2TCPIP_H_BUG
  261. +#undef FreeAddrInfoEx
  262. +#endif
  263.      FreeAddrInfoEx(res);
  264.  out:
  265.      if (status) {
  266. diff --git a/daemon/service.c b/daemon/service.c
  267. index 2b19668..81d9072 100644
  268. --- a/daemon/service.c
  269. +++ b/daemon/service.c
  270. @@ -27,6 +27,9 @@ FUNCTIONS:
  271.  #include <stdlib.h>
  272.  #include <process.h>
  273.  #include <tchar.h>
  274. +#ifdef UNICODE
  275. +#include <shellapi.h>
  276. +#endif
  277.  
  278.  #include "service.h"
  279.  
  280. diff --git a/daemon/sid.c b/daemon/sid.c
  281. index 412b33f..5326994 100644
  282. --- a/daemon/sid.c
  283. +++ b/daemon/sid.c
  284. @@ -351,7 +351,7 @@ int map_nfs4servername_2_sid(nfs41_daemon_globals *nfs41dg, int query, DWORD *si
  285.      }
  286.  #endif /* NFS41_DRIVER_FEATURE_MAP_UNMAPPED_USER_TO_UNIXUSER_SID */
  287.  
  288. -    status = LookupAccountName(NULL, name, NULL, sid_len, NULL, &tmp, &sid_type);
  289. +    status = LookupAccountNameA(NULL, name, NULL, sid_len, NULL, &tmp, &sid_type);
  290.      dprintf(ACLLVL, "map_nfs4servername_2_sid(query=%x,name='%s'): LookupAccountName returned %d "
  291.          "GetLastError %d name len %d domain len %d\n",
  292.          query, name, status, GetLastError(), *sid_len, tmp);
  293. @@ -369,7 +369,7 @@ int map_nfs4servername_2_sid(nfs41_daemon_globals *nfs41dg, int query, DWORD *si
  294.          tmp_buf = (LPSTR) malloc(tmp);
  295.          if (tmp_buf == NULL)
  296.              goto out_free_sid;
  297. -        status = LookupAccountName(NULL, name, *sid, sid_len, tmp_buf,
  298. +        status = LookupAccountNameA(NULL, name, *sid, sid_len, tmp_buf,
  299.                                      &tmp, &sid_type);
  300.          free(tmp_buf);
  301.          if (!status) {
  302. diff --git a/daemon/util.c b/daemon/util.c
  303. index 95e0d7f..cae4130 100644
  304. --- a/daemon/util.c
  305. +++ b/daemon/util.c
  306. @@ -443,11 +443,11 @@ int create_silly_rename(
  307.      StringCchCopyNA(name, NFS41_MAX_COMPONENT_LEN+1, silly->name, silly->len);
  308.  
  309.      tmp = (char*)silly->name;
  310. -    StringCchPrintf(tmp, end - tmp, ".%s.", name);
  311. +    StringCchPrintfA(tmp, end - tmp, ".%s.", name);
  312.      tmp += (size_t)silly->len + 2L;
  313.  
  314.      for (i = 0; i < 16; i++, tmp++)
  315. -        StringCchPrintf(tmp, end - tmp, "%x", fhmd5[i]);
  316. +        StringCchPrintfA(tmp, end - tmp, "%x", fhmd5[i]);
  317.  
  318.      path->len = path->len + extra_len;
  319.      silly->len = silly->len + extra_len;
  320. diff --git a/install/nfsreginst.c b/install/nfsreginst.c
  321. index 66e1997..9ea1502 100644
  322. --- a/install/nfsreginst.c
  323. +++ b/install/nfsreginst.c
  324. @@ -102,7 +102,7 @@ BOOL RdrSetProviderOrderString( __in LPTSTR OrderString )
  325.  
  326.      if ( CreateKey( PROVIDER_ORDER_KEY, &hOrderKey ) )
  327.      {
  328. -        ProviderOrderKeyValues[0].dwLength = ( _tcsclen( OrderString ) + 1 ) * sizeof( TCHAR );
  329. +        ProviderOrderKeyValues[0].dwLength = (DWORD)(( _tcsclen( OrderString ) + 1 ) * sizeof( TCHAR ));
  330.          ProviderOrderKeyValues[0].pvValue = OrderString;
  331.          WriteRegistryKeyValues( hOrderKey,
  332.                                  sizeof(ProviderOrderKeyValues) / sizeof(REGENTRY),
  333. diff --git a/mount/options.c b/mount/options.c
  334. index 11bdca9..c6a6439 100644
  335. --- a/mount/options.c
  336. +++ b/mount/options.c
  337. @@ -164,7 +164,7 @@ static void RecursivePrintEaInformation(
  338.          TEXT("EaValueLength:       %5u\n")
  339.          TEXT("EaName:   %16ls\n")
  340.          TEXT("EaValue:  %16ls\n\n"),
  341. -        (ULONG_PTR)EA % sizeof(ULONG),
  342. +        (unsigned long)((ULONG_PTR)EA % sizeof(ULONG)),
  343.          EA->NextEntryOffset,
  344.          EA->Flags,
  345.          EA->EaNameLength,

Submit a correction or amendment below (click here to make a fresh posting)
After submitting an amendment, you'll be able to view the differences between the old and new posts easily.

Syntax highlighting:

To highlight particular lines, prefix each line with {%HIGHLIGHT}




All content is user-submitted.
The administrators of this site (kpaste.net) are not responsible for their content.
Abuse reports should be emailed to us at