Skip to content

Commit

Permalink
Check token string length to know if a valid string is present as poi…
Browse files Browse the repository at this point in the history
…nter can have other use
  • Loading branch information
sgranjoux committed Nov 21, 2009
1 parent 8341892 commit f3621b8
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion libanjuta/anjuta-token-file.c
Original file line number Diff line number Diff line change
Expand Up @@ -299,7 +299,7 @@ anjuta_token_file_update (AnjutaTokenFile *file, AnjutaToken *token)
for (prev = token; prev != NULL; prev = anjuta_token_previous (prev))
{
gint flags = anjuta_token_get_flags (prev);
if ((anjuta_token_get_string (prev) != NULL) && !(flags & (ANJUTA_TOKEN_ADDED | ANJUTA_TOKEN_REMOVED))) break;
if ((anjuta_token_get_length (prev) != 0) && !(flags & (ANJUTA_TOKEN_ADDED | ANJUTA_TOKEN_REMOVED))) break;
token = prev;
}

Expand Down
2 changes: 1 addition & 1 deletion libanjuta/anjuta-token-style.c
Original file line number Diff line number Diff line change
Expand Up @@ -273,7 +273,7 @@ anjuta_token_style_format (AnjutaTokenStyle *style, AnjutaToken *list)
for (prev = list; prev != NULL; prev = anjuta_token_previous (prev))
{
gint flags = anjuta_token_get_flags (prev);
if ((anjuta_token_get_string (prev) != NULL) && !(flags & (ANJUTA_TOKEN_ADDED | ANJUTA_TOKEN_REMOVED))) break;
if ((anjuta_token_get_length (prev) != 0) && !(flags & (ANJUTA_TOKEN_ADDED | ANJUTA_TOKEN_REMOVED))) break;
list = prev;
}

Expand Down

0 comments on commit f3621b8

Please sign in to comment.