Show
Ignore:
Timestamp:
09/07/06 23:48:17 (2 years ago)
Author:
alexander
Message:

Previously, due to a programming error (reuse of the loop variable
for other purpose inside the loop) the CD wouldn't find itself when booting
from /dev/hdd if /dev/hdb contained a wrong CD. This bug is now fixed.

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • branches/6.2/packages/initramfs/init.c

    r1676 r1719  
    1717        "/dev/hda", "/dev/hdb", "/dev/hdc", "/dev/hdd", "/dev/hde", "/dev/hdf", "/dev/hdg", "/dev/hdh", 
    1818        "/dev/sr0", "/dev/sr1", "/dev/sr2", "/dev/sr3", "/dev/sr4", "/dev/sr5", "/dev/sr6", "/dev/sr7", 
    19         NULL, 
     19        NULL 
    2020}; 
    2121 
     
    182182        struct iso_primary_descriptor pd; 
    183183        int i; 
     184        int correct_cd; 
    184185 
    185186        for(i=0;devices[i]!=NULL;i++) 
     
    237238                   generated by the livecd Makefiles */ 
    238239 
    239                 i = strncmp(VOLUME_ID, pd.volume_id, strlen(VOLUME_ID)); 
    240                 if (i!=0) { 
     240                correct_cd = strncmp(VOLUME_ID, pd.volume_id, strlen(VOLUME_ID)); 
     241                if (correct_cd!=0) { 
    241242                        printf("This is not the correct CD. Moving on...\n"); 
    242243                        close(fd);