strftime前对struct tm初始化
This commit is contained in:
1
cache/src/tango_cache_tools.cpp
vendored
1
cache/src/tango_cache_tools.cpp
vendored
@@ -232,6 +232,7 @@ time_t expires_hdr2timestamp(const char *expires_val, int len)
|
||||
return 0;
|
||||
}
|
||||
|
||||
memset(&tm, 0, sizeof(struct tm));
|
||||
if(strptime(expires_val, "%a, %d %b %Y %T", &tm) == NULL)
|
||||
{
|
||||
return 0;
|
||||
|
||||
Reference in New Issue
Block a user