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

json的key值为字符串类型,但是当只含有数字和.的时候处理有问题 #735

Closed
baijian opened this issue Jul 21, 2016 · 0 comments
Labels
Milestone

Comments

@baijian
Copy link

baijian commented Jul 21, 2016

String a = "{\"key\":\"value\",\"10.0.1.1\":\"haha\"}";
         Object x = JSON.parse(a);
        JSONPath.set(x, "$.test" , "abc");
        Object o = JSONPath.eval(x, "$.10\\.0\\.1\\.1");

异常:
Exception in thread "main" java.lang.NumberFormatException: For input string: "10.0.1.1"

@wenshao wenshao added this to the 1.2.15 milestone Jul 21, 2016
@wenshao wenshao added the bug label Jul 21, 2016
wenshao added a commit that referenced this issue Jul 22, 2016
@wenshao wenshao closed this as completed Jul 31, 2016
asa1997 pushed a commit to Be-Secure/fastjson that referenced this issue Feb 8, 2023
asa1997 pushed a commit to Be-Secure/fastjson that referenced this issue Feb 8, 2023
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