~ilya-yanok/ubuntu/precise/grub2/fix-for-948716

« back to all changes in this revision

Viewing changes to normal/script.c

  • Committer: Bazaar Package Importer
  • Author(s): Robert Millan
  • Date: 2008-01-28 00:01:11 UTC
  • mto: (17.3.1 squeeze) (1.9.1 upstream)
  • mto: This revision was merged to the branch mainline in revision 16.
  • Revision ID: james.westby@ubuntu.com-20080128000111-0764agvqzg601o1d
Tags: upstream-1.95+20080128
ImportĀ upstreamĀ versionĀ 1.95+20080128

Show diffs side-by-side

added added

removed removed

Lines of Context:
24
24
 
25
25
/* It is not possible to deallocate the memory when a syntax error was
26
26
   found.  Because of that it is required to keep track of all memory
27
 
   allocations.  The memory is free'ed in case of an error, or
 
27
   allocations.  The memory is freed in case of an error, or
28
28
   assigned to the parsed script when parsing was successful.  */
29
29
 
30
30
/* XXX */
31
31
 
32
32
/* In case of the normal malloc, some additional bytes are allocated
33
33
   for this datastructure.  All reserved memory is stored in a linked
34
 
   list so it can be easily free'ed.  The original memory can be found
 
34
   list so it can be easily freed.  The original memory can be found
35
35
   from &mem.  */
36
36
struct grub_script_mem
37
37
{
230
230
  cmd = grub_script_malloc (state, sizeof (*cmd));
231
231
  cmd->cmd.exec = grub_script_execute_menuentry;
232
232
  cmd->cmd.next = 0;
233
 
  /* XXX: Check if this memory is properly free'ed.  */
 
233
  /* XXX: Check if this memory is properly freed.  */
234
234
  cmd->sourcecode = sourcecode;
235
235
  cmd->title = title;
236
236
  cmd->options = options;