Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 29 Jan 1999 20:21:51 +0900 (JST)
From:      dcs@newsguy.com
To:        FreeBSD-gnats-submit@FreeBSD.ORG
Subject:   bin/9772: ficlExecFD wants to eat the cake and have it at the same time
Message-ID:  <199901291121.UAA00382@daniel.sobral>

next in thread | raw e-mail | index | archive | help

>Number:         9772
>Category:       bin
>Synopsis:       ficlExecFD vmThrows error
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    freebsd-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Fri Jan 29 03:30:01 PST 1999
>Closed-Date:
>Last-Modified:
>Originator:     Daniel C. Sobral
>Release:        FreeBSD 4.0-CURRENT i386
>Organization:
>Environment:

	Current as of Jan 24

>Description:

	ficlExecFD says it will return either VM_OUTOFTEXT or the
appropriate error code, but then goes and vmThrows any error. Worse yet,
there is no garantee that ficlExecFD was called from inside a ficlExec
"safety net" to catch the vmThrow. In fact, the only place currently
calling ficlExecFD in all source code is garantee not to be inside a
ficlExec execution instance... :-)

>How-To-Repeat:

	Copy a file with error to /boot/boot.4th and reboot

>Fix:
	
	Apply the following fix:


--- src/sys/boot/ficl/ficl.c	1999/01/28 17:01:53	1.12
+++ src/sys/boot/ficl/ficl.c	1999/01/29 11:14:44
@@ -377,8 +377,7 @@
 	if(rval != VM_QUIT && rval != VM_USEREXIT && rval != VM_OUTOFTEXT)
         {
             pVM->sourceID = id;
-            vmThrowErr(pVM, "ficlExecFD: Error at line %d", nLine);
-            break; 
+            return rval; 
         }
     }
     /*
>Release-Note:
>Audit-Trail:
>Unformatted:

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-bugs" in the body of the message



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199901291121.UAA00382>