camcontrol.c (40319) | camcontrol.c (41112) |
---|---|
1/* 2 * Copyright (c) 1997, 1998 Kenneth D. Merry 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 --- 11 unchanged lines hidden (view full) --- 20 * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 21 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 22 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 23 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 24 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 25 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 26 * SUCH DAMAGE. 27 * | 1/* 2 * Copyright (c) 1997, 1998 Kenneth D. Merry 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 --- 11 unchanged lines hidden (view full) --- 20 * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 21 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 22 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 23 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 24 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 25 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 26 * SUCH DAMAGE. 27 * |
28 * $Id: camcontrol.c,v 1.4 1998/10/13 16:23:26 ken Exp $ | 28 * $Id: camcontrol.c,v 1.5 1998/10/13 22:02:38 ken Exp $ |
29 */ 30 31#include <sys/ioctl.h> 32#include <sys/types.h> 33#include <stdio.h> 34#include <stdlib.h> 35#include <string.h> 36#include <unistd.h> --- 1958 unchanged lines hidden (view full) --- 1995 && ((arglist & CAM_ARG_OPT_MASK) != CAM_ARG_DEBUG)) { 1996 1997 if ((cam_dev = cam_open_spec_device(device,unit,O_RDWR, 1998 NULL))== NULL) 1999 errx(1,"%s", cam_errbuf); 2000 } 2001 2002 /* | 29 */ 30 31#include <sys/ioctl.h> 32#include <sys/types.h> 33#include <stdio.h> 34#include <stdlib.h> 35#include <string.h> 36#include <unistd.h> --- 1958 unchanged lines hidden (view full) --- 1995 && ((arglist & CAM_ARG_OPT_MASK) != CAM_ARG_DEBUG)) { 1996 1997 if ((cam_dev = cam_open_spec_device(device,unit,O_RDWR, 1998 NULL))== NULL) 1999 errx(1,"%s", cam_errbuf); 2000 } 2001 2002 /* |
2003 * Reset optind to 2, and reset getopt, so these routines cam parse | 2003 * Reset optind to 2, and reset getopt, so these routines can parse |
2004 * the arguments again. 2005 */ 2006 optind = 2; 2007 optreset = 1; 2008 2009 switch(arglist & CAM_ARG_OPT_MASK) { 2010 case CAM_ARG_DEVLIST: 2011 error = getdevlist(cam_dev); --- 45 unchanged lines hidden --- | 2004 * the arguments again. 2005 */ 2006 optind = 2; 2007 optreset = 1; 2008 2009 switch(arglist & CAM_ARG_OPT_MASK) { 2010 case CAM_ARG_DEVLIST: 2011 error = getdevlist(cam_dev); --- 45 unchanged lines hidden --- |