-
Notifications
You must be signed in to change notification settings - Fork 99
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
format null as \u0000 when calling with --json #214
Conversation
@@ -263,8 +269,8 @@ struct option { | |||
}; | |||
|
|||
#define MAX_QPAIRS 1000 | |||
char *qpairs[MAX_QPAIRS]; /* encoded */ | |||
char *qpairsdec[MAX_QPAIRS]; /* decoded */ | |||
struct string qpairs[MAX_QPAIRS]; /* encoded */ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
what is the point of this change for encoded qpairs?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It might make it easier to have both types using the same layout so switching between them gets easy.
0917612
to
3c729bf
Compare
Control characters without a special escape sequence e.g. %00 or %06 were being encoded as "u0006" instead of "\u0006". Ref: curl/trurl#214 (comment) Closes #11414
Control characters without a special escape sequence e.g. %00 or %06 were being encoded as "u0006" instead of "\u0006". Ref: curl/trurl#214 (comment) Closes curl#11414
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think this looks good. Can you have a look at the little merge conflict and I'll be ready to merge!
6b99b01
to
0dd09f8
Compare
Ahh there we go! it should be all set to merge now bagder, thanks! |
Control characters without a special escape sequence e.g. %00 or %06 were being encoded as "u0006" instead of "\u0006". Ref: curl/trurl#214 (comment) Closes curl#11414
--json
encode a null byte as\u0000
instead of.
struct string
and makesqpairs
andqpairsdec
use this instead of a char*