X-Git-Url: https://git.gag.com/?a=blobdiff_plain;f=restore-src%2Famrestore.c;h=aef9ba429d57cd8e417ffd09855993c1024e6069;hb=2df780bff19c457b0debb7adc29972a0bc2a5dc2;hp=dca74ba3c0c043fc753b9372a104b04e5bc0da02;hpb=0de2ad0a86685398621fb8ffa6990c029681bb3a;p=debian%2Famanda diff --git a/restore-src/amrestore.c b/restore-src/amrestore.c index dca74ba..aef9ba4 100644 --- a/restore-src/amrestore.c +++ b/restore-src/amrestore.c @@ -24,7 +24,7 @@ * file named AUTHORS, in the root directory of this distribution. */ /* - * $Id: amrestore.c,v 1.28.2.4.4.3.2.8.2.3 2004/11/19 18:12:30 martinea Exp $ + * $Id: amrestore.c,v 1.28.2.4.4.3.2.8.2.4 2005/09/20 21:31:52 jrjackson Exp $ * * retrieves files from an amanda tape */ @@ -477,22 +477,13 @@ char **argv; int found_match; int arg_state; amwait_t compress_status; - int fd; int r = 0; char *e; char *err; char *label = NULL; int count_error; - for(fd = 3; fd < FD_SETSIZE; fd++) { - /* - * Make sure nobody spoofs us with a lot of extra open files - * that would cause an open we do to get a very high file - * descriptor, which in turn might be used as an index into - * an array (e.g. an fd_set). - */ - close(fd); - } + safe_fd(-1, 0); set_pname("amrestore");