Author: marcel
Date: Mon Apr  4 16:59:46 2011
New Revision: 220332
URL: http://svn.freebsd.org/changeset/base/220332

Log:
  Fix a long standing bug where file_load() passes down the global loadaddr
  to the l_load() method in the file_formats structure, while being passed
  an address as an argument (dest). With file_load() calling arch_loadaddr()
  now, this bug is a little bit more significant.
  
  Spotted by: nyan@ (nice catch!)

Modified:
  head/sys/boot/common/module.c

Modified: head/sys/boot/common/module.c
==============================================================================
--- head/sys/boot/common/module.c       Mon Apr  4 16:47:42 2011        
(r220331)
+++ head/sys/boot/common/module.c       Mon Apr  4 16:59:46 2011        
(r220332)
@@ -280,7 +280,7 @@ file_load(char *filename, vm_offset_t de
 
     error = EFTYPE;
     for (i = 0, fp = NULL; file_formats[i] && fp == NULL; i++) {
-       error = (file_formats[i]->l_load)(filename, loadaddr, &fp);
+       error = (file_formats[i]->l_load)(filename, dest, &fp);
        if (error == 0) {
            fp->f_loader = i;           /* remember the loader */
            *result = fp;
_______________________________________________
svn-src-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"

Reply via email to