X-Git-Url: https://git.dogcows.com/gitweb?a=blobdiff_plain;f=openbox%2Fparse.c;h=80a918cb89e8e76140acfcf6d952e967fbf675b8;hb=47cc179781aec47bf317c5c15879fa0dad95de86;hp=37e3998b9cdc57519371900889f3f5abe6d73524;hpb=e2c3582a5c0230cae0571e8f92829b910039f179;p=chaz%2Fopenbox diff --git a/openbox/parse.c b/openbox/parse.c index 37e3998b..80a918cb 100644 --- a/openbox/parse.c +++ b/openbox/parse.c @@ -33,11 +33,11 @@ void parse_reg_section(char *section, ParseFunc func) void parse_free_token(ParseToken *token) { - GSList *it; + GList *it; switch (token->type) { case TOKEN_STRING: - g_free(token-data.string); + g_free(token->data.string); break; case TOKEN_IDENTIFIER: g_free(token->data.identifier); @@ -47,7 +47,7 @@ void parse_free_token(ParseToken *token) parse_free_token(it->data); g_free(it->data); } - g_slist_free(token->data.list); + g_list_free(token->data.list); break; case TOKEN_REAL: case TOKEN_INTEGER: @@ -82,7 +82,7 @@ static void parse_rc_token(ParseToken *token) if (id == NULL) { if (token->type == TOKEN_IDENTIFIER) { - id = token.identifier; + id = token->data.identifier; return; } else { yyerror("syntax error"); @@ -96,16 +96,16 @@ static void parse_rc_token(ParseToken *token) } } else if (!got_val) { if (token->type == TOKEN_STRING) { - s = token.string; - got_val = type; + s = token->data.string; + got_val = token->type; return; } else if (token->type == TOKEN_BOOL) { - b = token.bool; - got_val = type; + b = token->data.bool; + got_val = token->type; return; } else if (token->type == TOKEN_INTEGER) { - i = token.integer; - got_val = type; + i = token->data.integer; + got_val = token->type; return; } else yyerror("syntax error"); @@ -140,5 +140,5 @@ static void parse_rc_token(ParseToken *token) id = s = NULL; got_eq = FALSE; got_val = 0; - parse_free_token(token->type, token); + parse_free_token(token); }