Changeset 360 for trunk/src/kern_head.c


Ignore:
Timestamp:
Oct 18, 2011, 11:51:57 PM (10 years ago)
Author:
katerina
Message:

Fix for ticket #266 (kern_head does not work on 3.x kernels).

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/kern_head.c

    r346 r360  
    441441    }
    442442
    443   if (minor != 4 && minor != 6)
    444     {
    445       fprintf(stderr, "kern_head: kernel %s not supported\n", p);
    446       exit (EXIT_FAILURE);
     443  if (major == 2)
     444    {
     445      if (minor != 4 && minor != 6)
     446        {
     447          fprintf(stderr, "kern_head: kernel %s not supported\n", p);
     448          exit (EXIT_FAILURE);
     449        }
    447450    }
    448451
     
    492495          sh_smap[i].addr    = 0UL;
    493496        }
    494       if (minor == 6) /* fix syscall map for 2.6 */
     497      if (major > 2 || minor == 6) /* fix syscall map for 2.6 */
    495498        {
    496499          strcpy(sh_smap[0].name,   "sys_restart_syscall");
Note: See TracChangeset for help on using the changeset viewer.