Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Scanf.sscanf "%S" doesn't handle "\\xff" #4923

Closed
vicuna opened this issue Nov 17, 2009 · 2 comments
Closed

Scanf.sscanf "%S" doesn't handle "\\xff" #4923

vicuna opened this issue Nov 17, 2009 · 2 comments
Assignees
Labels

Comments

@vicuna
Copy link

vicuna commented Nov 17, 2009

Original bug ID: 4923
Reporter: gildor
Assigned to: @pierreweis
Status: closed (set by @pierreweis on 2009-11-19T10:25:19Z)
Resolution: fixed
Priority: normal
Severity: major
Version: 3.11.1
Fixed in version: 3.11.2+dev
Category: ~DO NOT USE (was: OCaml general)

Bug description

The string "\xff" is valid, but cannot be parsed using Scanf.sscanf.

Step to reproduce:

Scanf.sscanf ""\xef\xbb\xbf"" "%S" (fun s -> s);;

Exception: Scanf.Scan_failure "scanf: bad input at char number 2: x".

Regards
Sylvain Le Gall

@vicuna
Copy link
Author

vicuna commented Nov 19, 2009

Comment author: @pierreweis

Thank you for the bug report: indeed the \x notation was not yet implemented in Scanf.

@vicuna
Copy link
Author

vicuna commented Nov 19, 2009

Comment author: @pierreweis

The fix will be available in the forthcoming 3.11.2 release.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants