devicename.c (38466) | devicename.c (39662) |
---|---|
1/*- 2 * Copyright (c) 1998 Michael Smith <msmith@freebsd.org> 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 --- 9 unchanged lines hidden (view full) --- 18 * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 19 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 20 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 21 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 22 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 23 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 24 * SUCH DAMAGE. 25 * | 1/*- 2 * Copyright (c) 1998 Michael Smith <msmith@freebsd.org> 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 --- 9 unchanged lines hidden (view full) --- 18 * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 19 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 20 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 21 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 22 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 23 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 24 * SUCH DAMAGE. 25 * |
26 * $Id$ | 26 * $Id: devicename.c,v 1.1.1.1 1998/08/21 03:17:41 msmith Exp $ |
27 */ 28 29#include <stand.h> 30#include <string.h> 31#include <sys/disklabel.h> 32#include "bootstrap.h" 33#include "libi386.h" 34 --- 184 unchanged lines hidden (view full) --- 219/* 220 * Set currdev to suit the value being supplied in (value) 221 */ 222int 223i386_setcurrdev(struct env_var *ev, int flags, void *value) 224{ 225 struct i386_devdesc *ncurr; 226 int rv; | 27 */ 28 29#include <stand.h> 30#include <string.h> 31#include <sys/disklabel.h> 32#include "bootstrap.h" 33#include "libi386.h" 34 --- 184 unchanged lines hidden (view full) --- 219/* 220 * Set currdev to suit the value being supplied in (value) 221 */ 222int 223i386_setcurrdev(struct env_var *ev, int flags, void *value) 224{ 225 struct i386_devdesc *ncurr; 226 int rv; |
227 | 227 |
228 if ((rv = i386_parsedev(&ncurr, value, NULL)) != 0) 229 return(rv); 230 free(ncurr); 231 env_setenv(ev->ev_name, flags | EV_NOHOOK, value, NULL, NULL); 232 return(0); 233} 234 | 228 if ((rv = i386_parsedev(&ncurr, value, NULL)) != 0) 229 return(rv); 230 free(ncurr); 231 env_setenv(ev->ev_name, flags | EV_NOHOOK, value, NULL, NULL); 232 return(0); 233} 234 |