Magellan Linux

Diff of /tags/grubby-8_38/grubby.c

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 2960 by niro, Wed Jun 29 14:07:59 2016 UTC revision 2972 by niro, Thu Jun 30 10:17:00 2016 UTC
# Line 582  struct keywordTypes extlinuxKeywords[] = Line 582  struct keywordTypes extlinuxKeywords[] =
582      { "initrd",    LT_INITRD,      ' ', ',' },      { "initrd",    LT_INITRD,      ' ', ',' },
583      { "append",    LT_KERNELARGS,  ' ' },      { "append",    LT_KERNELARGS,  ' ' },
584      { "prompt",     LT_UNKNOWN,     ' ' },      { "prompt",     LT_UNKNOWN,     ' ' },
585        { "fdt",        LT_DEVTREE,     ' ' },
586        { "fdtdir",     LT_DEVTREE,     ' ' },
587      { NULL,    0, 0 },      { NULL,    0, 0 },
588  };  };
589  int useextlinuxmenu;  int useextlinuxmenu;
# Line 2370  void displayEntry(struct singleEntry * e Line 2372  void displayEntry(struct singleEntry * e
2372      } else {      } else {
2373   char * title;   char * title;
2374   line = getLineByType(LT_MENUENTRY, entry->lines);   line = getLineByType(LT_MENUENTRY, entry->lines);
2375   title = grub2ExtractTitle(line);   if (line) {
2376   if (title)      title = grub2ExtractTitle(line);
2377      printf("title=%s\n", title);      if (title)
2378     printf("title=%s\n", title);
2379     }
2380      }      }
2381    
2382      for (j = 0, line = entry->lines; line; line = line->next) {      for (j = 0, line = entry->lines; line; line = line->next) {
# Line 3323  int addMBInitrd(struct grubConfig * cfg, Line 3327  int addMBInitrd(struct grubConfig * cfg,
3327    
3328   /* if title is supplied, the entry's title must match it. */   /* if title is supplied, the entry's title must match it. */
3329   if (title) {   if (title) {
3330        char *linetitle;
3331    
3332      line = getLineByType(LT_TITLE|LT_MENUENTRY, entry->lines);      line = getLineByType(LT_TITLE|LT_MENUENTRY, entry->lines);
3333      char *linetitle = extractTitle(line);      if (!line)
3334     continue;
3335    
3336        linetitle = extractTitle(line);
3337      if (!linetitle)      if (!linetitle)
3338   continue;   continue;
3339      if (strcmp(title, linetitle)) {      if (strcmp(title, linetitle)) {
# Line 3373  int updateInitrd(struct grubConfig * cfg Line 3381  int updateInitrd(struct grubConfig * cfg
3381    
3382   /* if title is supplied, the entry's title must match it. */   /* if title is supplied, the entry's title must match it. */
3383   if (title) {   if (title) {
3384        char *linetitle;
3385    
3386      line = getLineByType(LT_TITLE|LT_MENUENTRY, entry->lines);      line = getLineByType(LT_TITLE|LT_MENUENTRY, entry->lines);
3387      char *linetitle = extractTitle(line);      if (!line)
3388     continue;
3389    
3390        linetitle = extractTitle(line);
3391      if (!linetitle)      if (!linetitle)
3392   continue;   continue;
3393      if (strcmp(title, linetitle)) {      if (strcmp(title, linetitle)) {
# Line 4259  int main(int argc, const char ** argv) { Line 4271  int main(int argc, const char ** argv) {
4271      _("display the title of the default kernel") },      _("display the title of the default kernel") },
4272   { "devtree", 0, POPT_ARG_STRING, &newDevTreePath, 0,   { "devtree", 0, POPT_ARG_STRING, &newDevTreePath, 0,
4273      _("device tree file for new stanza"), _("dtb-path") },      _("device tree file for new stanza"), _("dtb-path") },
4274     { "devtreedir", 0, POPT_ARG_STRING, &newDevTreePath, 0,
4275        _("device tree directory for new stanza"), _("dtb-path") },
4276   { "elilo", 0, POPT_ARG_NONE, &configureELilo, 0,   { "elilo", 0, POPT_ARG_NONE, &configureELilo, 0,
4277      _("configure elilo bootloader") },      _("configure elilo bootloader") },
4278   { "efi", 0, POPT_ARG_NONE, &isEfi, 0,   { "efi", 0, POPT_ARG_NONE, &isEfi, 0,

Legend:
Removed from v.2960  
changed lines
  Added in v.2972