Deleted Added
full compact
cmdline.c (228761) cmdline.c (229592)
1/*-
2 * Copyright (c) 2003-2007 Tim Kientzle
3 * All rights reserved.
4 *
5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions
7 * are met:
8 * 1. Redistributions of source code must retain the above copyright

--- 12 unchanged lines hidden (view full) ---

21 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
22 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
23 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
24 * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
25 */
26
27
28#include "cpio_platform.h"
1/*-
2 * Copyright (c) 2003-2007 Tim Kientzle
3 * All rights reserved.
4 *
5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions
7 * are met:
8 * 1. Redistributions of source code must retain the above copyright

--- 12 unchanged lines hidden (view full) ---

21 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
22 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
23 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
24 * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
25 */
26
27
28#include "cpio_platform.h"
29__FBSDID("$FreeBSD: src/usr.bin/cpio/cmdline.c,v 1.5 2008/12/06 07:30:40 kientzle Exp $");
29__FBSDID("$FreeBSD: stable/9/contrib/libarchive/cpio/cmdline.c 229592 2012-01-05 12:06:54Z mm $");
30
31#ifdef HAVE_ERRNO_H
32#include <errno.h>
33#endif
34#ifdef HAVE_GRP_H
35#include <grp.h>
36#endif
37#ifdef HAVE_PWD_H

--- 242 unchanged lines hidden (view full) ---

280 *
281 * Where uid/gid are decimal representations and groupname/username
282 * are names to be looked up in system database. Note that we try
283 * to look up an argument as a name first, then try numeric parsing.
284 *
285 * A period can be used instead of the colon.
286 *
287 * Sets uid/gid return as appropriate, -1 indicates uid/gid not specified.
30
31#ifdef HAVE_ERRNO_H
32#include <errno.h>
33#endif
34#ifdef HAVE_GRP_H
35#include <grp.h>
36#endif
37#ifdef HAVE_PWD_H

--- 242 unchanged lines hidden (view full) ---

280 *
281 * Where uid/gid are decimal representations and groupname/username
282 * are names to be looked up in system database. Note that we try
283 * to look up an argument as a name first, then try numeric parsing.
284 *
285 * A period can be used instead of the colon.
286 *
287 * Sets uid/gid return as appropriate, -1 indicates uid/gid not specified.
288 * TODO: If the spec uses uname/gname, then return those to the caller
289 * as well. If the spec provides uid/gid, just return names as NULL.
288 *
289 * Returns NULL if no error, otherwise returns error string for display.
290 *
291 */
292const char *
293owner_parse(const char *spec, int *uid, int *gid)
294{
295 static char errbuff[128];

--- 74 unchanged lines hidden ---
290 *
291 * Returns NULL if no error, otherwise returns error string for display.
292 *
293 */
294const char *
295owner_parse(const char *spec, int *uid, int *gid)
296{
297 static char errbuff[128];

--- 74 unchanged lines hidden ---