Do not try to duplicate an array when source equals to destination.
所有检测均成功
The build was successful.

这个提交包含在:
Rafal Kupiec 2019-06-20 13:36:30 +02:00
父节点 59811ac742
当前提交 19d0628afc
签署人:: belliash
GPG 密钥 ID: 4E829243E0CFE6B4

查看文件

@ -1004,6 +1004,12 @@ PH7_PRIVATE sxi32 PH7_HashmapDup(ph7_hashmap *pSrc, ph7_hashmap *pDest) {
ph7_value sKey, *pVal;
sxi32 rc;
sxu32 n;
if(pSrc == pDest) {
/* This should NOT really happen, but never try to duplicate
* an array when source and the destination are the same arrays.
*/
return SXRET_OK;
}
/* Point to the first inserted entry in the source */
pEntry = pSrc->pFirst;
/* Perform the duplication */