summaryrefslogtreecommitdiff
path: root/archivers/libarchive/files/doc/man/archive_write_free.3
blob: efda9aaaa810ea1f970bef0a3129b7ff4be96fbb (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
.TH ARCHIVE_WRITE_FREE 3 "February 2, 2012" ""
.SH NAME
.ad l
\fB\%archive_write_fail\fP,
\fB\%archive_write_close\fP,
\fB\%archive_write_finish\fP,
\fB\%archive_write_free\fP
\- functions for creating archives
.SH LIBRARY
.ad l
Streaming Archive Library (libarchive, -larchive)
.SH SYNOPSIS
.ad l
\fB#include <archive.h>\fP
.br
\fIint\fP
.br
\fB\%archive_write_fail\fP(\fI\%struct\ archive\ *\fP);
.br
\fIint\fP
.br
\fB\%archive_write_close\fP(\fI\%struct\ archive\ *\fP);
.br
\fIint\fP
.br
\fB\%archive_write_finish\fP(\fI\%struct\ archive\ *\fP);
.br
\fIint\fP
.br
\fB\%archive_write_free\fP(\fI\%struct\ archive\ *\fP);
.SH DESCRIPTION
.ad l
.RS 5
.TP
\fB\%archive_write_fail\fP()
Always returns
\fBARCHIVE_FATAL\fP.
This marks the archive object as being unusable;
after calling this function, the only call that can succeed is
\fB\%archive_write_free\fP()
to release the resources.
This can be used to speed recovery when the archive creation
must be aborted.
Note that the created archive is likely to be malformed in this case;
.TP
\fB\%archive_write_close\fP()
Complete the archive and invoke the close callback.
.TP
\fB\%archive_write_finish\fP()
This is a deprecated synonym for
\fB\%archive_write_free\fP().
.TP
\fB\%archive_write_free\fP()
Invokes
\fB\%archive_write_close\fP()
if necessary, then releases all resources.
If you need detailed information about
\fB\%archive_write_close\fP()
failures, you should be careful to call it separately, as
you cannot obtain error information after
\fB\%archive_write_free\fP()
returns.
.RE
.SH RETURN VALUES
.ad l
These functions return
\fBARCHIVE_OK\fP
on success, or
\fBARCHIVE_FATAL\fP.
.SH ERRORS
.ad l
Detailed error codes and textual descriptions are available from the
\fB\%archive_errno\fP()
and
\fB\%archive_error_string\fP()
functions.
.SH SEE ALSO
.ad l
\fBtar\fP(1),
\fBarchive_write_set_options\fP(3),
\fBlibarchive\fP(3),
\fBcpio\fP(5),
\fBmtree\fP(5),
\fBtar\fP(5)