mirror of
https://github.com/alsa-project/alsa-tools.git
synced 2025-10-28 05:40:23 -04:00
as10k1 - increase max number of macros and check the size
- Increase the max number of macros to 30. - Check the current number of macros to avoid segfault.
This commit is contained in:
parent
4ca5af3d8e
commit
54becc11d0
2 changed files with 5 additions and 1 deletions
|
|
@ -46,6 +46,10 @@ void new_macro(char *symbol, char *line, char *operand)
|
|||
{
|
||||
extern int source_line_num;
|
||||
struct sym *sym;
|
||||
|
||||
if (macro_ctn >= MAX_DEF_MACRO)
|
||||
as_exit("Parse Error: Too many macros");
|
||||
|
||||
if(isalpha(*symbol)==0)
|
||||
as_exit("Parse Error: Symbol must start with an alpha character");
|
||||
|
||||
|
|
|
|||
|
|
@ -108,7 +108,7 @@ struct macrdef{
|
|||
#define NO_SYM "__NO_NAME"
|
||||
|
||||
|
||||
#define MAX_DEF_MACRO 25
|
||||
#define MAX_DEF_MACRO 30
|
||||
#define MAX_MAC_DEPTH 5
|
||||
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue