diff --git a/source/common/src/cos.c b/source/common/src/cos.c index db95fb02bb..f36ab42ada 100644 --- a/source/common/src/cos.c +++ b/source/common/src/cos.c @@ -722,9 +722,10 @@ static SArray *getListByPrefix(const char *prefix) { return data.objectArray; } } else { - taosArrayDestroyEx(data.objectArray, s3FreeObjectKey); s3PrintError(__func__, data.status, data.err_msg); } + + taosArrayDestroyEx(data.objectArray, s3FreeObjectKey); return NULL; }