Skip to content

sscanf processes %% as an argument if a % is detected in the string. #870

@cylismaori

Description

@cylismaori

eval string msg, tmp1, code, tmp2; msg = "%^BOLD%^%^BLUE%^A blue scarf.%^RESET%^"; return sscanf(msg, "%s%%^%s%%^%s", tmp1, code, tmp2);
Result = 5

eval string foo, bar;return sscanf("this is a string","%s%%%s",foo, bar);
Result = 1
eval string foo, bar;return sscanf("this is% a string","%s%%%s",foo, bar);
Result = 3

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions