Imported Upstream version 1.1.3
[platform/upstream/libzip.git] / man / zip_file_set_mtime.man
1 .TH "ZIP_FILE_SET_MTIME" "3" "August 5, 2014" "NiH" "Library Functions Manual"
2 .nh
3 .if n .ad l
4 .SH "NAME"
5 \fBzip_file_set_mtime\fR
6 \- set last modification time (mtime) for file in zip
7 .SH "LIBRARY"
8 libzip (-lzip)
9 .SH "SYNOPSIS"
10 \fB#include <zip.h>\fR
11 .sp
12 \fIint\fR
13 .PD 0
14 .HP 4n
15 \fBzip_set_file_mtime\fR(\fIzip_t\ *archive\fR, \fIzip_uint64_t\ index\fR, \fItime_t\ mtime\fR, \fIzip_flags_t\ flags\fR);
16 .PD
17 .SH "DESCRIPTION"
18 The
19 \fBzip_file_set_mtime\fR()
20 function sets the last modification time (mtime) for the file at
21 position
22 \fIindex\fR
23 in the zip archive to
24 \fImtime\fR.
25 Currently, no support for any
26 \fIflags\fR
27 is implemented.
28 .SH "RETURN VALUES"
29 Upon successful completion 0 is returned.
30 Otherwise, \-1 is returned and the error information in
31 \fIarchive\fR
32 is set to indicate the error.
33 .SH "ERRORS"
34 \fBzip_file_set_mtime\fR()
35 fails if:
36 .TP 19n
37 [\fRZIP_ER_INVAL\fR]
38 \fIindex\fR
39 is not a valid file index in
40 \fIarchive\fR.
41 .TP 19n
42 [\fRZIP_ER_MEMORY\fR]
43 Required memory could not be allocated.
44 .TP 19n
45 [\fRZIP_ER_RDONLY\fR]
46 The
47 \fIarchive\fR
48 was opened in read-only mode.
49 .SH "SEE ALSO"
50 libzip(3),
51 zip_stat(3)
52 .SH "AUTHORS"
53 Dieter Baron <\fIdillo@nih.at\fR>
54 and
55 Thomas Klausner <\fItk@giga.or.at\fR>