Imported Upstream version 3.4.1
[platform/upstream/libarchive.git] / doc / html / archive_write_free.3.html
1 <!-- Creator     : groff version 1.22.4 -->
2 <!-- CreationDate: Mon Dec 30 01:41:24 2019 -->
3 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
4 "http://www.w3.org/TR/html4/loose.dtd">
5 <html>
6 <head>
7 <meta name="generator" content="groff -Thtml, see www.gnu.org">
8 <meta http-equiv="Content-Type" content="text/html; charset=US-ASCII">
9 <meta name="Content-Style" content="text/css">
10 <style type="text/css">
11        p       { margin-top: 0; margin-bottom: 0; vertical-align: top }
12        pre     { margin-top: 0; margin-bottom: 0; vertical-align: top }
13        table   { margin-top: 0; margin-bottom: 0; vertical-align: top }
14        h1      { text-align: center }
15 </style>
16 <title></title>
17 </head>
18 <body>
19
20 <hr>
21
22
23 <p>ARCHIVE_WRITE_FREE(3) BSD Library Functions Manual
24 ARCHIVE_WRITE_FREE(3)</p>
25
26 <p style="margin-top: 1em"><b>NAME</b></p>
27
28 <p style="margin-left:6%;"><b>archive_write_fail</b>,
29 <b>archive_write_close</b>, <b>archive_write_finish</b>,
30 <b>archive_write_free</b> &mdash; functions for creating
31 archives</p>
32
33 <p style="margin-top: 1em"><b>LIBRARY</b></p>
34
35 <p style="margin-left:6%;">Streaming Archive Library
36 (libarchive, -larchive)</p>
37
38 <p style="margin-top: 1em"><b>SYNOPSIS</b></p>
39
40 <p style="margin-left:6%;"><b>#include
41 &lt;archive.h&gt;</b></p>
42
43 <p style="margin-left:6%; margin-top: 1em"><i>int</i></p>
44
45
46 <p style="margin-left:12%;"><b>archive_write_fail</b>(<i>struct&nbsp;archive&nbsp;*</i>);</p>
47
48 <p style="margin-left:6%; margin-top: 1em"><i>int</i></p>
49
50
51 <p style="margin-left:12%;"><b>archive_write_close</b>(<i>struct&nbsp;archive&nbsp;*</i>);</p>
52
53 <p style="margin-left:6%; margin-top: 1em"><i>int</i></p>
54
55
56 <p style="margin-left:12%;"><b>archive_write_finish</b>(<i>struct&nbsp;archive&nbsp;*</i>);</p>
57
58 <p style="margin-left:6%; margin-top: 1em"><i>int</i></p>
59
60
61 <p style="margin-left:12%;"><b>archive_write_free</b>(<i>struct&nbsp;archive&nbsp;*</i>);</p>
62
63 <p style="margin-top: 1em"><b>DESCRIPTION <br>
64 archive_write_fail</b>()</p>
65
66 <p style="margin-left:17%;">Always returns
67 <b>ARCHIVE_FATAL</b>. This marks the archive object as being
68 unusable; after calling this function, the only call that
69 can succeed is <b>archive_write_free</b>() to release the
70 resources. This can be used to speed recovery when the
71 archive creation must be aborted. Note that the created
72 archive is likely to be malformed in this case;</p>
73
74
75 <p style="margin-top: 1em"><b>archive_write_close</b>()</p>
76
77 <p style="margin-left:17%;">Complete the archive and invoke
78 the close callback.</p>
79
80
81 <p style="margin-top: 1em"><b>archive_write_finish</b>()</p>
82
83 <p style="margin-left:17%;">This is a deprecated synonym
84 for <b>archive_write_free</b>().</p>
85
86 <p style="margin-top: 1em"><b>archive_write_free</b>()</p>
87
88 <p style="margin-left:17%;">Invokes
89 <b>archive_write_close</b>() if necessary, then releases all
90 resources. If you need detailed information about
91 <b>archive_write_close</b>() failures, you should be careful
92 to call it separately, as you cannot obtain error
93 information after <b>archive_write_free</b>() returns.</p>
94
95 <p style="margin-top: 1em"><b>RETURN VALUES</b></p>
96
97 <p style="margin-left:6%;">These functions return
98 <b>ARCHIVE_OK</b> on success, or <b>ARCHIVE_FATAL</b>.</p>
99
100 <p style="margin-top: 1em"><b>ERRORS</b></p>
101
102 <p style="margin-left:6%;">Detailed error codes and textual
103 descriptions are available from the <b>archive_errno</b>()
104 and <b>archive_error_string</b>() functions.</p>
105
106 <p style="margin-top: 1em"><b>SEE ALSO</b></p>
107
108 <p style="margin-left:6%;">tar(1),
109 archive_write_set_options(3), libarchive(3), cpio(5),
110 mtree(5), tar(5)</p>
111
112 <p style="margin-left:6%; margin-top: 1em">BSD
113 February&nbsp;2, 2012 BSD</p>
114 <hr>
115 </body>
116 </html>