diff options
| author | Brian Somers <brian@FreeBSD.org> | 2005-01-12 03:25:55 +0000 |
|---|---|---|
| committer | Brian Somers <brian@FreeBSD.org> | 2005-01-12 03:25:55 +0000 |
| commit | 0e32d64e56a10617d06b5fdf44df6266b3fadb21 (patch) | |
| tree | 6078adfd93dcb4c40972d27708b9624be4722673 /bin | |
| parent | b96d69488ca5cdc29bde4e9d709a6baf4767669d (diff) | |
Notes
Diffstat (limited to 'bin')
| -rw-r--r-- | bin/pax/ar_subs.c | 8 | ||||
| -rw-r--r-- | bin/pax/extern.h | 1 | ||||
| -rw-r--r-- | bin/pax/ftree.c | 12 |
3 files changed, 19 insertions, 2 deletions
diff --git a/bin/pax/ar_subs.c b/bin/pax/ar_subs.c index f16facf98d56..da275c2dacb0 100644 --- a/bin/pax/ar_subs.c +++ b/bin/pax/ar_subs.c @@ -400,8 +400,10 @@ wr_archive(ARCHD *arcn, int is_app) /* * check if this file meets user specified options match. */ - if (sel_chk(arcn) != 0) + if (sel_chk(arcn) != 0) { + ftree_notsel(); continue; + } fd = -1; if (uflag) { /* @@ -785,8 +787,10 @@ copy(void) /* * check if this file meets user specified options */ - if (sel_chk(arcn) != 0) + if (sel_chk(arcn) != 0) { + ftree_notsel(); continue; + } /* * if there is already a file in the destination directory with diff --git a/bin/pax/extern.h b/bin/pax/extern.h index b0d0237280b9..e7167928e2f9 100644 --- a/bin/pax/extern.h +++ b/bin/pax/extern.h @@ -155,6 +155,7 @@ int set_crc(ARCHD *, int); int ftree_start(void); int ftree_add(char *, int); void ftree_sel(ARCHD *); +void ftree_notsel(void); void ftree_chk(void); int next_file(ARCHD *); diff --git a/bin/pax/ftree.c b/bin/pax/ftree.c index 36c0de51c693..f402c568ddfa 100644 --- a/bin/pax/ftree.c +++ b/bin/pax/ftree.c @@ -214,6 +214,18 @@ ftree_sel(ARCHD *arcn) } /* + * ftree_notsel() + * this entry has not been selected by pax. + */ + +void +ftree_notsel() +{ + if (ftent != NULL) + (void)fts_set(ftsp, ftent, FTS_SKIP); +} + +/* * ftree_chk() * called at end on pax execution. Prints all those file args that did not * have a selected member (reference count still 0) |
