I’m porting flex/bison on windows and build M4 code inside executable.

 

After upgrading gnulibs I caught a runtime error “memory exhausted” in macro.c file.

 

  if (use_argc_stack)

    obstack_free (&argc_stack, argv[0]);

  else

    obstack_free (&arguments, NULL);

  obstack_blank (&argv_stack, -argc * sizeof (token_data *)); << crash here!!! Line 390

}

 

It seems now obstack_blank function doesn’t allow negative numbers (see /lib/obstack.h file)

Because obstack.temp.i has type as size_t (it was ptr_diff_t before).

 

Could you verify the following line works as expected in Linux?

 

  obstack_blank (&argv_stack, -argc * sizeof (token_data *));

 

Best regards,

   Alex

 

Reply via email to