Displaying 2 results from an estimated 2 matches for "cat_fil".
Did you mean:
cat_file
2010 Mar 18
1
argv[0] doesn't contain module name and cat.c32 hangs with Syslinux 4.00-pre36
...00-pre36, argv[0] returns some garbage characters.
ISOLINUX 3.85 2010-02-20 ETCD Copyright (C) 1994-2010 H. Peter Anvin et al
argv = 0x00182c44
argv[0] = 0x07fbffc3 = ""
argv[1] = 0x00182c34 = "isolinux.cfg"
argv[2] = 0x00000000 = "(null)"
File = isolinux.cfg
DEFAULT cat_file
LABEL cat_file
COM32 cat.c32
APPEND isolinux.cfg
boot:
EXTLINUX 4.00 4.00-pre36 Copyright (C) 1994-2010 H. Peter Anvin et al
Press 1 to see the menu
Hello, World! from (hello.c)
argv = 0x001e1e48
argv[0] = 0x07fdffbf = "?"
argv[1] = 0x001e1e38 = "extlinux.conf"
argv[2] = 0...
2011 Apr 01
0
[GIT PULL] elflink cmdline
...strncmp(prefix, me->label, len))
+ printf(" %s\n", me->label);
+ }
+}
+
static struct menu_entry *find_label(const char *str)
{
const char *p;
@@ -606,6 +618,78 @@ static char *is_message_name(char *cmdstr, enum message_number *msgnr)
return NULL;
}
+static int cat_file(const char *filename)
+{
+ FILE *f;
+ char line[2048];
+
+ f = fopen(filename, "r");
+ if (!f)
+ return -1;
+
+ while (fgets(line, sizeof(line), f) != NULL)
+ printf("%s", line);
+
+ fclose(f);
+ return 0;
+}
+
+void cat_help_file(int key)
+{
+ struct menu *cm = current_menu;...