diff options
author | Sergey Poznyakoff <gray@gnu.org.ua> | 2017-07-24 10:46:44 +0300 |
---|---|---|
committer | Sergey Poznyakoff <gray@gnu.org.ua> | 2017-07-24 10:46:44 +0300 |
commit | ead370a83f981ccf3d288dbe222fd362ec801f79 (patch) | |
tree | 74dfef1fe64df5e659ffbd3f74023453913bbc14 | |
parent | 3f686a2e5768174553b39697576171f5862433e3 (diff) | |
download | runcap-ead370a83f981ccf3d288dbe222fd362ec801f79.tar.gz runcap-ead370a83f981ccf3d288dbe222fd362ec801f79.tar.bz2 |
Improve manpage
-rw-r--r-- | runcap.3 | 17 |
1 files changed, 11 insertions, 6 deletions
@@ -13,7 +13,7 @@ | |||
13 | .\" | 13 | .\" |
14 | .\" You should have received a copy of the GNU General Public License | 14 | .\" You should have received a copy of the GNU General Public License |
15 | .\" along with runcap. If not, see <http://www.gnu.org/licenses/>. | 15 | .\" along with runcap. If not, see <http://www.gnu.org/licenses/>. |
16 | .TH RUNCAP 2 "July 19, 2017" "RUNCAP" "User Commands" | 16 | .TH RUNCAP 2 "July 24, 2017" "RUNCAP" "User Commands" |
17 | .SH NAME | 17 | .SH NAME |
18 | runcap \- run external process and capture its stdout and stderr | 18 | runcap \- run external process and capture its stdout and stderr |
19 | .SH SYNOPSIS | 19 | .SH SYNOPSIS |
@@ -28,7 +28,7 @@ runcap \- run external process and capture its stdout and stderr | |||
28 | .BI " char **" pstr ", size_t *" psize ); | 28 | .BI " char **" pstr ", size_t *" psize ); |
29 | .sp | 29 | .sp |
30 | .BI "off_t runcap_tell(struct runcap *" rc ", int " stream ); | 30 | .BI "off_t runcap_tell(struct runcap *" rc ", int " stream ); |
31 | .BI "int runcap_seek(struct runcap *" rc ", int " stream ", off_t " off ", int " whence); | 31 | .BI "off_t runcap_seek(struct runcap *" rc ", int " stream ", off_t " off ", int " whence); |
32 | .BI "int runcap_rewind(struct runcap *" rc ", int " stream ); | 32 | .BI "int runcap_rewind(struct runcap *" rc ", int " stream ); |
33 | .SH DESCRIPTION | 33 | .SH DESCRIPTION |
34 | The function | 34 | The function |
@@ -317,17 +317,22 @@ returns the number of retrieved characters (including the newline) on | |||
317 | success, 0 on end of stream, and -1 on error. | 317 | success, 0 on end of stream, and -1 on error. |
318 | .PP | 318 | .PP |
319 | .B runcap_tell() | 319 | .B runcap_tell() |
320 | returns the current offset (a non-negative value) on success, and -1 | 320 | and |
321 | .B runcap_seek() | ||
322 | return the current offset (a non-negative value) on success, and -1 | ||
321 | on error. | 323 | on error. |
322 | .PP | 324 | .PP |
323 | .B runcap_seek() | ||
324 | and | ||
325 | .B runcap_rewind() | 325 | .B runcap_rewind() |
326 | return 0 on success and -1 on error. | 326 | returns 0 on success and -1 on error. |
327 | .PP | 327 | .PP |
328 | When returning an error (-1), all functions set the global \fBerrno\fR | 328 | When returning an error (-1), all functions set the global \fBerrno\fR |
329 | variable to the code describing the error. | 329 | variable to the code describing the error. |
330 | .SH EXAMPLE | 330 | .SH EXAMPLE |
331 | The function below runs the | ||
332 | .BR tar (1) | ||
333 | command in verbose mode and returns its output as an array of | ||
334 | strings. | ||
335 | .PP | ||
331 | .in +4n | 336 | .in +4n |
332 | .nf | 337 | .nf |
333 | char ** | 338 | char ** |