Skip to content

Commit ae80263

Browse files
committed
fixed:does not reply http message when storeage key notfound
1 parent 5a27962 commit ae80263

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

XEngine_Source/XEngine_StorageApp/StorageApp_Download.cpp

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -259,6 +259,11 @@ BOOL XEngine_Task_HttpDownload(LPCTSTR lpszClientAddr, LPCTSTR lpszMsgBuffer, in
259259
//分布式存储
260260
if (!APIHelp_Distributed_DLStorage(pSt_HTTPParam->tszHttpUri, st_LoadbalanceCfg.st_LoadBalance.pStl_ListBucket, &st_StorageBucket))
261261
{
262+
st_HDRParam.bIsClose = TRUE;
263+
st_HDRParam.nHttpCode = 404;
264+
265+
RfcComponents_HttpServer_SendMsgEx(xhDLHttp, tszSDBuffer, &nSDLen, &st_HDRParam);
266+
XEngine_Net_SendMsg(lpszClientAddr, tszSDBuffer, nSDLen, STORAGE_NETTYPE_HTTPDOWNLOAD);
262267
XLOG_PRINT(xhLog, XENGINE_HELPCOMPONENTS_XLOG_IN_LOGLEVEL_ERROR, _T("下载客户端:%s,请求文件失败,可能BUCKET:%s 不正确,错误:%lX"), lpszClientAddr, pSt_HTTPParam->tszHttpUri, StorageHelp_GetLastError());
263268
return FALSE;
264269
}

0 commit comments

Comments
 (0)