Skip to content

Commit

Permalink
Merge pull request #55 from tencentyun/feature_huberyxxiao_d66f053a
Browse files Browse the repository at this point in the history
Feature huberyxxiao d66f053a
  • Loading branch information
Huberyxiao authored Apr 12, 2024
2 parents fbbbdd0 + 66b0e65 commit a99626e
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 2 deletions.
8 changes: 8 additions & 0 deletions cos_c_sdk/cos_object.c
Original file line number Diff line number Diff line change
Expand Up @@ -986,6 +986,10 @@ int cos_gen_presigned_url(const cos_request_options_t *options,
http_method_e method,
cos_string_t *presigned_url)
{
if (object == NULL || object->len == 0){
cos_str_set(presigned_url, "ObjectName does not support empty, please check!");
return COSE_UNKNOWN_ERROR;
}
cos_string_t signstr;
int res;
cos_http_request_t *req = NULL;
Expand Down Expand Up @@ -1059,6 +1063,10 @@ int cos_gen_presigned_url_safe(const cos_request_options_t *options,
int sign_host,
cos_string_t *presigned_url)
{
if (object == NULL || object->len == 0){
cos_str_set(presigned_url, "ObjectName does not support empty, please check!");
return COSE_UNKNOWN_ERROR;
}
cos_string_t signstr;
int res;
cos_http_request_t *req = NULL;
Expand Down
2 changes: 1 addition & 1 deletion cos_c_sdk/cos_sys_define.h
Original file line number Diff line number Diff line change
Expand Up @@ -132,7 +132,7 @@ typedef apr_array_header_t cos_array_header_t;
#define CR (char) 13
#define CRLF "\x0d\x0a"

#define COS_VERSION "5.0.16"
#define COS_VERSION "5.0.17"
#define COS_VER "cos-sdk-c/" COS_VERSION

#define COS_HTTP_PREFIX "http://"
Expand Down
2 changes: 1 addition & 1 deletion cos_c_sdk/cos_sys_util.c
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ static const char *g_s_mon[] = {
};

static const char g_s_gmt_format[] = "%s, %.2d %s %.4d %.2d:%.2d:%.2d GMT";
static int retry_change_domin_config = 1;
static int retry_change_domin_config = COS_FALSE;

static cos_table_t *g_sign_header_table = NULL;
static cos_pool_t *g_table_pool = NULL;
Expand Down

0 comments on commit a99626e

Please sign in to comment.