We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
Description'
Please ensure that the markdown structure is maintained.
HTTP API does not encode special chars in json, for example "" in stream name.
Please describe the issue you encountered here. ' Make sure to maintain the markdown structure.
v3.0-b4
Replay
How to replay bug?
Steps to reproduce the bug
Just start stream with name "\\" and it will then produce invalid JSON in /v1/streams API.
Expect
Expected behavior
Please describe your expectation
Describe what you expect to happen
JSON could be parseable even if it contains invalid stream names
TRANS_BY_GPT3
The text was updated successfully, but these errors were encountered:
I will consider it.
Sorry, something went wrong.
Example of returning JSON in Node.js:
'use strict'; const Koa = require('koa'); const Router = require('koa-router'); const moment = require('moment'); const app = new Koa(); const router = new Router(); router.all('/hello-koa', async (ctx) => { ctx.body = { errCode: 0, errorMessage: "", data: { `msg: 'Hello视频',` // @see https://momentjs.com/docs/#/manipulating/utc-offset/ now: moment().utcOffset(moment.duration(8, 'hours').asMinutes()).format('YYYY-MM-DD HH:mm:ss'), }, } }); app.use(router.routes()); app.listen(9000, () => { console.log(`Server start on http://localhost:9000`); });
nodejs-json-utf8.pcapng.zip
Fixed by 34b968a
// @see https://github.com/ossrs/srs/pull/1758/files#diff-9568479ef5cb0aa1ade2381e11e9c066c01bf9c4bbed70ffa27094d08bb27380R370 // @see https://github.com/json-parser/json-builder/blob/2d8c6671926d104c5dcd43ccd2b1431a3f0299e0/json-builder.c#L495
winlinvip
Successfully merging a pull request may close this issue.
Description'
Please ensure that the markdown structure is maintained.
HTTP API does not encode special chars in json, for example "" in stream name.
v3.0-b4
Replay
How to replay bug?
Just start stream with name "\\" and it will then produce invalid JSON in /v1/streams API.
Expect
Please describe your expectation
JSON could be parseable even if it contains invalid stream names
TRANS_BY_GPT3
The text was updated successfully, but these errors were encountered: