[Libwebsockets] lejp float parsing issues

Michael Heinen mbheinen at gmail.com
Mon Jan 1 18:58:49 CET 2018

I'm probably missing something simple, but I can't seem to get the json
parser to correctly parse json that has a float in it. I am using
the libwebsockets-test-lejp and I have a simple my.json file like:

[mheinen at morken_rhel7_1 bin]$ cat my.json

Piping to libwebsockets-test-lejp gives the following output:

[mheinen at test_rhel7_1 bin]$ cat my.json | ./libwebsockets-test-lejp
[2018/01/01 11:45:00:5382] NOTICE: libwebsockets-test-lejp  (C)2017
andy at warmcat.com
[2018/01/01 11:45:00:5382] NOTICE:   usage: cat my.json |

[2018/01/01 11:45:00:5382] NOTICE: path: 'string' (LEJPCB_PAIR_NAME)
[2018/01/01 11:45:00:5382] NOTICE:    value 'test'  (LEJPCB_VAL_STR_END)
[2018/01/01 11:45:00:5382] NOTICE: path: 'integer' (LEJPCB_PAIR_NAME)
[2018/01/01 11:45:00:5383] NOTICE:    value '123'  (LEJPCB_VAL_NUM_INT)
[2018/01/01 11:45:00:5383] NOTICE: path: 'float' (LEJPCB_PAIR_NAME)
[2018/01/01 11:45:00:5383] NOTICE: okay

It seems LEJPCB_VAL_NUM_FLOAT never gets called. I am on latest master.

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://libwebsockets.org/pipermail/libwebsockets/attachments/20180101/6c5bbfda/attachment.html>

More information about the Libwebsockets mailing list