Skip to content

Commit 0374273

Browse files
authored
Merge pull request #19 from libxengine/develop
V3.4.1 Merge
2 parents a75fc4c + 4ad5a8b commit 0374273

File tree

20 files changed

+103
-44
lines changed

20 files changed

+103
-44
lines changed

XEngine_Release/XEngine_Config/XEngine_Config.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -75,6 +75,7 @@
7575
},
7676
"XVer":{
7777
"StorageVersion":[
78+
"3.4.1.1001 Build20220126",
7879
"3.4.0.1001 Build20220121",
7980
"3.3.0.1001 Build20220106",
8081
"3.2.0.1001 Build20211211",

XEngine_Source/StorageModule_APIHelp/APIHelp_Api/APIHelp_Api.cpp

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,6 @@ BOOL CAPIHelp_Api::APIHelp_Api_ProxyAuth(TCHAR* ptszUser, TCHAR* ptszPass, TCHAR
5454
{
5555
APIHelp_IsErrorOccur = FALSE;
5656

57-
int nSDLen = 1024;
5857
int nAuthType = 0;
5958
int nAuthLen = MAX_PATH;
6059

XEngine_Source/StorageModule_APIHelp/APIHelp_Distributed/APIHelp_Distributed.cpp

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -257,6 +257,25 @@ BOOL CAPIHelp_Distributed::APIHelp_Distributed_UPStorage(LPCTSTR lpszMsgBuffer,
257257
{
258258
return FALSE;
259259
}
260+
//判断目录大小是否正常
261+
int nListCount = 0;
262+
__int64u nDirCount = 0; //当前目录大小
263+
CHAR** ppListFile;
264+
SystemApi_File_EnumFile(pSt_StorageBucket->tszFilePath, &ppListFile, &nListCount, NULL, NULL, TRUE, 1);
265+
for (int j = 0; j < nListCount; j++)
266+
{
267+
struct __stat64 st_FStat;
268+
_stat64(ppListFile[j], &st_FStat);
269+
nDirCount += st_FStat.st_size;
270+
}
271+
BaseLib_OperatorMemory_Free((XPPPMEM)&ppListFile, nListCount);
272+
//如果当前目录大小大于设定的大小.
273+
if (nDirCount >= APIHelp_Distributed_GetSize(pSt_StorageBucket->tszBuckSize))
274+
{
275+
APIHelp_IsErrorOccur = TRUE;
276+
APIHelp_dwErrorCode = ERROR_STORAGE_MODULE_APIHELP_SIZE;
277+
return FALSE;
278+
}
260279
}
261280
else
262281
{

XEngine_Source/StorageModule_APIHelp/APIHelp_Error.h

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,4 +18,5 @@
1818
#define ERROR_STORAGE_MODULE_APIHELP_NOTLENGTH 0x0030012 //没有长度信息
1919
#define ERROR_STORAGE_MODULE_APIHELP_PARSELEN 0x0030013 //解析长度失败
2020
#define ERROR_STORAGE_MODULE_APIHELP_NOTHASH 0x0030014 //没有HASH值
21-
#define ERROR_STORAGE_MODULE_APIHELP_NOTMATCH 0x0030015 //HASH不匹配
21+
#define ERROR_STORAGE_MODULE_APIHELP_NOTMATCH 0x0030015 //HASH不匹配
22+
#define ERROR_STORAGE_MODULE_APIHELP_SIZE 0x0030016 //目录大小已经满了

XEngine_Source/StorageModule_APIHelp/StorageModule_APIHelp.vcxproj

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@
4343
<ConfigurationType>DynamicLibrary</ConfigurationType>
4444
<UseDebugLibraries>true</UseDebugLibraries>
4545
<PlatformToolset>v142</PlatformToolset>
46-
<CharacterSet>Unicode</CharacterSet>
46+
<CharacterSet>MultiByte</CharacterSet>
4747
</PropertyGroup>
4848
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">
4949
<ConfigurationType>DynamicLibrary</ConfigurationType>
@@ -82,6 +82,8 @@
8282
</PropertyGroup>
8383
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
8484
<LinkIncremental>true</LinkIncremental>
85+
<IncludePath>$(XEngine_Include);$(IncludePath)</IncludePath>
86+
<LibraryPath>$(XEngine_Lib64);$(LibraryPath)</LibraryPath>
8587
</PropertyGroup>
8688
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
8789
<LinkIncremental>false</LinkIncremental>
@@ -131,7 +133,7 @@
131133
<ClCompile>
132134
<WarningLevel>Level3</WarningLevel>
133135
<SDLCheck>true</SDLCheck>
134-
<PreprocessorDefinitions>_DEBUG;STORAGEMODULEAPIHELP_EXPORTS;_WINDOWS;_USRDLL;%(PreprocessorDefinitions)</PreprocessorDefinitions>
136+
<PreprocessorDefinitions>_DEBUG;STORAGEMODULEAPIHELP_EXPORTS;_WINDOWS;_USRDLL;_CRT_SECURE_NO_WARNINGS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
135137
<ConformanceMode>true</ConformanceMode>
136138
<PrecompiledHeader>Use</PrecompiledHeader>
137139
<PrecompiledHeaderFile>pch.h</PrecompiledHeaderFile>

XEngine_Source/StorageModule_Config/StorageModule_Config.vcxproj

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@
4343
<ConfigurationType>DynamicLibrary</ConfigurationType>
4444
<UseDebugLibraries>true</UseDebugLibraries>
4545
<PlatformToolset>v142</PlatformToolset>
46-
<CharacterSet>Unicode</CharacterSet>
46+
<CharacterSet>MultiByte</CharacterSet>
4747
</PropertyGroup>
4848
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">
4949
<ConfigurationType>DynamicLibrary</ConfigurationType>
@@ -81,6 +81,7 @@
8181
</PropertyGroup>
8282
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
8383
<LinkIncremental>true</LinkIncremental>
84+
<IncludePath>$(XEngine_Include);$(IncludePath)</IncludePath>
8485
</PropertyGroup>
8586
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
8687
<LinkIncremental>false</LinkIncremental>
@@ -129,7 +130,7 @@
129130
<ClCompile>
130131
<WarningLevel>Level3</WarningLevel>
131132
<SDLCheck>true</SDLCheck>
132-
<PreprocessorDefinitions>_DEBUG;STORAGEMODULECONFIG_EXPORTS;_WINDOWS;_USRDLL;%(PreprocessorDefinitions)</PreprocessorDefinitions>
133+
<PreprocessorDefinitions>_DEBUG;STORAGEMODULECONFIG_EXPORTS;_WINDOWS;_USRDLL;_CRT_SECURE_NO_WARNINGS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
133134
<ConformanceMode>true</ConformanceMode>
134135
<PrecompiledHeader>Use</PrecompiledHeader>
135136
<PrecompiledHeaderFile>pch.h</PrecompiledHeaderFile>

XEngine_Source/StorageModule_Protocol/StorageModule_Protocol.vcxproj

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@
4343
<ConfigurationType>DynamicLibrary</ConfigurationType>
4444
<UseDebugLibraries>true</UseDebugLibraries>
4545
<PlatformToolset>v142</PlatformToolset>
46-
<CharacterSet>Unicode</CharacterSet>
46+
<CharacterSet>MultiByte</CharacterSet>
4747
</PropertyGroup>
4848
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">
4949
<ConfigurationType>DynamicLibrary</ConfigurationType>
@@ -82,6 +82,8 @@
8282
</PropertyGroup>
8383
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
8484
<LinkIncremental>true</LinkIncremental>
85+
<IncludePath>$(XEngine_Include);$(IncludePath)</IncludePath>
86+
<LibraryPath>$(XEngine_Lib64);$(LibraryPath)</LibraryPath>
8587
</PropertyGroup>
8688
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
8789
<LinkIncremental>false</LinkIncremental>
@@ -131,7 +133,7 @@
131133
<ClCompile>
132134
<WarningLevel>Level3</WarningLevel>
133135
<SDLCheck>true</SDLCheck>
134-
<PreprocessorDefinitions>_DEBUG;STORAGEMODULEPROTOCOL_EXPORTS;_WINDOWS;_USRDLL;%(PreprocessorDefinitions)</PreprocessorDefinitions>
136+
<PreprocessorDefinitions>_DEBUG;STORAGEMODULEPROTOCOL_EXPORTS;_WINDOWS;_USRDLL;_CRT_SECURE_NO_WARNINGS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
135137
<ConformanceMode>true</ConformanceMode>
136138
<PrecompiledHeader>Use</PrecompiledHeader>
137139
<PrecompiledHeaderFile>pch.h</PrecompiledHeaderFile>

XEngine_Source/StorageModule_Session/StorageModule_Session.vcxproj

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@
4343
<ConfigurationType>DynamicLibrary</ConfigurationType>
4444
<UseDebugLibraries>true</UseDebugLibraries>
4545
<PlatformToolset>v142</PlatformToolset>
46-
<CharacterSet>Unicode</CharacterSet>
46+
<CharacterSet>MultiByte</CharacterSet>
4747
</PropertyGroup>
4848
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">
4949
<ConfigurationType>DynamicLibrary</ConfigurationType>
@@ -73,20 +73,22 @@
7373
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
7474
<LinkIncremental>true</LinkIncremental>
7575
<IncludePath>$(XEngine_Include);$(IncludePath)</IncludePath>
76-
<LibraryPath>$(XEngine_Library);$(LibraryPath)</LibraryPath>
76+
<LibraryPath>$(XEngine_Lib32);$(LibraryPath)</LibraryPath>
7777
</PropertyGroup>
7878
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
7979
<LinkIncremental>false</LinkIncremental>
8080
<IncludePath>$(XEngine_Include);$(IncludePath)</IncludePath>
81-
<LibraryPath>$(XEngine_Library);$(LibraryPath)</LibraryPath>
81+
<LibraryPath>$(XEngine_Lib32);$(LibraryPath)</LibraryPath>
8282
</PropertyGroup>
8383
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
8484
<LinkIncremental>true</LinkIncremental>
85+
<IncludePath>$(XEngine_Include);$(IncludePath)</IncludePath>
86+
<LibraryPath>$(XEngine_Lib64);$(LibraryPath)</LibraryPath>
8587
</PropertyGroup>
8688
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
8789
<LinkIncremental>false</LinkIncremental>
8890
<IncludePath>$(XEngine_Include);$(IncludePath)</IncludePath>
89-
<LibraryPath>$(XEngine_Library);$(LibraryPath)</LibraryPath>
91+
<LibraryPath>$(XEngine_Lib64);$(LibraryPath)</LibraryPath>
9092
</PropertyGroup>
9193
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
9294
<ClCompile>
@@ -131,7 +133,7 @@
131133
<ClCompile>
132134
<WarningLevel>Level3</WarningLevel>
133135
<SDLCheck>true</SDLCheck>
134-
<PreprocessorDefinitions>_DEBUG;STORAGEMODULESESSION_EXPORTS;_WINDOWS;_USRDLL;%(PreprocessorDefinitions)</PreprocessorDefinitions>
136+
<PreprocessorDefinitions>_DEBUG;STORAGEMODULESESSION_EXPORTS;_WINDOWS;_USRDLL;_CRT_SECURE_NO_WARNINGS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
135137
<ConformanceMode>true</ConformanceMode>
136138
<PrecompiledHeader>Use</PrecompiledHeader>
137139
<PrecompiledHeaderFile>pch.h</PrecompiledHeaderFile>

XEngine_Source/StorageModule_Session/pch.h

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@
1111
// 添加要在此处预编译的标头
1212
#include "framework.h"
1313
#include <tchar.h>
14+
#include <io.h>
1415
#else
1516
#include <unistd.h>
1617
#endif
@@ -20,7 +21,6 @@
2021
#include <string.h>
2122
#include <errno.h>
2223
#include <time.h>
23-
#include <io.h>
2424
#include <sys/types.h>
2525
#include <sys/stat.h>
2626
#include <list>
@@ -50,9 +50,5 @@ extern BOOL Session_IsErrorOccur;
5050
extern DWORD Session_dwErrorCode;
5151

5252
#ifdef _WINDOWS
53-
#ifdef _WIN64
54-
#pragma comment(lib,"x64/XEngine_BaseLib/XEngine_BaseLib.lib")
55-
#else
56-
#pragma comment(lib,"x86/XEngine_BaseLib/XEngine_BaseLib.lib")
57-
#endif
53+
#pragma comment(lib,"XEngine_BaseLib/XEngine_BaseLib.lib")
5854
#endif

XEngine_Source/VSCopy_x64.bat

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
copy /y "%XEngine_Library%\x64\XEngine_BaseLib\XEngine_BaseLib.dll" "./"
2+
copy /y "%XEngine_Library%\x64\XEngine_BaseLib\XEngine_Algorithm.dll" "./"
3+
copy /y "%XEngine_Library%\x64\XEngine_Core\XEngine_Core.dll" "./"
4+
copy /y "%XEngine_Library%\x64\XEngine_Core\XEngine_ManagePool.dll" "./"
5+
copy /y "%XEngine_Library%\x64\XEngine_Core\XEngine_NetXApi.dll" "./"
6+
copy /y "%XEngine_Library%\x64\XEngine_Core\XEngine_OPenSsl.dll" "./"
7+
8+
copy /y "%XEngine_Library%\x64\XEngine_SystemSdk\XEngine_SystemApi.dll" "./"
9+
10+
copy /y "%XEngine_Library%\x64\XEngine_HelpComponents\HelpComponents_DataBase.dll" "./"
11+
copy /y "%XEngine_Library%\x64\XEngine_HelpComponents\HelpComponents_Packets.dll" "./"
12+
copy /y "%XEngine_Library%\x64\XEngine_HelpComponents\HelpComponents_XLog.dll" "./"
13+
14+
copy /y "%XEngine_Library%\x64\XEngine_NetHelp\NetHelp_APIHelp.dll" "./"
15+
16+
copy /y "%XEngine_Library%\x64\XEngine_RfcComponents\RfcComponents_HttpServer.dll" "./"
17+
18+
copy /y "%XEngine_Library%\x64\XEngine_HelpComponents\bson-1.0.dll" "./"
19+
copy /y "%XEngine_Library%\x64\XEngine_HelpComponents\mongoc-1.0.dll" "./"
20+
copy /y "%XEngine_Library%\x64\XEngine_HelpComponents\libmariadb.dll" "./"
21+
copy /y "%XEngine_Library%\x64\XEngine_HelpComponents\libpq.dll" "./"
22+
copy /y "%XEngine_Library%\x64\XEngine_HelpComponents\sqlite3.dll" "./"
23+
copy /y "%XEngine_Library%\x64\XEngine_HelpComponents\zlib1.dll" "./"
24+
copy /y "%XEngine_Library%\x64\XEngine_HelpComponents\plugin\caching_sha2_password.dll" "./"
25+
copy /y "%XEngine_Library%\x64\XEngine_LibEx\libcrypto-1_1.dll" "./"
26+
copy /y "%XEngine_Library%\x64\XEngine_LibEx\libssl-1_1.dll" "./"
27+
copy /y "%XEngine_Library%\x64\XEngine_LibEx\libcurl.dll" "./"

0 commit comments

Comments
 (0)