diff options
Diffstat (limited to 'ext/zip/php_zip.c')
-rw-r--r-- | ext/zip/php_zip.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/ext/zip/php_zip.c b/ext/zip/php_zip.c index 8986279602..e7ca9cb477 100644 --- a/ext/zip/php_zip.c +++ b/ext/zip/php_zip.c @@ -258,6 +258,13 @@ static int php_zip_extract_file(struct zip * za, char *dest, char *file, size_t php_stream_write(stream, b, n); } + if (stream->wrapper->wops->stream_metadata) { + struct utimbuf ut; + + ut.modtime = ut.actime = sb.mtime; + stream->wrapper->wops->stream_metadata(stream->wrapper, fullpath, PHP_STREAM_META_TOUCH, &ut, NULL); + } + php_stream_close(stream); n = zip_fclose(zf); |