正在显示
2 个修改的文件
包含
7 行增加
和
7 行删除
@@ -431,14 +431,14 @@ int SrsHttpHooks::do_post(std::string url, std::string req, int& code, string& r | @@ -431,14 +431,14 @@ int SrsHttpHooks::do_post(std::string url, std::string req, int& code, string& r | ||
431 | // ensure the http status is ok. | 431 | // ensure the http status is ok. |
432 | // https://github.com/simple-rtmp-server/srs/issues/158 | 432 | // https://github.com/simple-rtmp-server/srs/issues/158 |
433 | if (code != SRS_CONSTS_HTTP_OK) { | 433 | if (code != SRS_CONSTS_HTTP_OK) { |
434 | - ret = ERROR_HTTP_STATUS_INVLIAD; | 434 | + ret = ERROR_HTTP_STATUS_INVALID; |
435 | srs_error("invalid response status=%d. ret=%d", code, ret); | 435 | srs_error("invalid response status=%d. ret=%d", code, ret); |
436 | return ret; | 436 | return ret; |
437 | } | 437 | } |
438 | 438 | ||
439 | // should never be empty. | 439 | // should never be empty. |
440 | if (res.empty()) { | 440 | if (res.empty()) { |
441 | - ret = ERROR_HTTP_DATA_INVLIAD; | 441 | + ret = ERROR_HTTP_DATA_INVALID; |
442 | srs_error("invalid empty response. ret=%d", ret); | 442 | srs_error("invalid empty response. ret=%d", ret); |
443 | return ret; | 443 | return ret; |
444 | } | 444 | } |
@@ -446,7 +446,7 @@ int SrsHttpHooks::do_post(std::string url, std::string req, int& code, string& r | @@ -446,7 +446,7 @@ int SrsHttpHooks::do_post(std::string url, std::string req, int& code, string& r | ||
446 | // parse string res to json. | 446 | // parse string res to json. |
447 | SrsJsonAny* info = SrsJsonAny::loads((char*)res.c_str()); | 447 | SrsJsonAny* info = SrsJsonAny::loads((char*)res.c_str()); |
448 | if (!info) { | 448 | if (!info) { |
449 | - ret = ERROR_HTTP_DATA_INVLIAD; | 449 | + ret = ERROR_HTTP_DATA_INVALID; |
450 | srs_error("invalid response %s. ret=%d", res.c_str(), ret); | 450 | srs_error("invalid response %s. ret=%d", res.c_str(), ret); |
451 | return ret; | 451 | return ret; |
452 | } | 452 | } |
@@ -455,7 +455,7 @@ int SrsHttpHooks::do_post(std::string url, std::string req, int& code, string& r | @@ -455,7 +455,7 @@ int SrsHttpHooks::do_post(std::string url, std::string req, int& code, string& r | ||
455 | // response error code in string. | 455 | // response error code in string. |
456 | if (!info->is_object()) { | 456 | if (!info->is_object()) { |
457 | if (res != SRS_HTTP_RESPONSE_OK) { | 457 | if (res != SRS_HTTP_RESPONSE_OK) { |
458 | - ret = ERROR_HTTP_DATA_INVLIAD; | 458 | + ret = ERROR_HTTP_DATA_INVALID; |
459 | srs_error("invalid response number %s. ret=%d", res.c_str(), ret); | 459 | srs_error("invalid response number %s. ret=%d", res.c_str(), ret); |
460 | return ret; | 460 | return ret; |
461 | } | 461 | } |
@@ -103,7 +103,7 @@ CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. | @@ -103,7 +103,7 @@ CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. | ||
103 | /////////////////////////////////////////////////////// | 103 | /////////////////////////////////////////////////////// |
104 | #define ERROR_RTMP_PLAIN_REQUIRED 2000 | 104 | #define ERROR_RTMP_PLAIN_REQUIRED 2000 |
105 | #define ERROR_RTMP_CHUNK_START 2001 | 105 | #define ERROR_RTMP_CHUNK_START 2001 |
106 | -#define ERROR_RTMP_MSG_INVLIAD_SIZE 2002 | 106 | +#define ERROR_RTMP_MSG_INVALID_SIZE 2002 |
107 | #define ERROR_RTMP_AMF0_DECODE 2003 | 107 | #define ERROR_RTMP_AMF0_DECODE 2003 |
108 | #define ERROR_RTMP_AMF0_INVALID 2004 | 108 | #define ERROR_RTMP_AMF0_INVALID 2004 |
109 | #define ERROR_RTMP_REQ_CONNECT 2005 | 109 | #define ERROR_RTMP_REQ_CONNECT 2005 |
@@ -170,7 +170,7 @@ CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. | @@ -170,7 +170,7 @@ CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. | ||
170 | #define ERROR_HLS_AAC_FRAME_LENGTH 3005 | 170 | #define ERROR_HLS_AAC_FRAME_LENGTH 3005 |
171 | #define ERROR_HLS_AVC_SAMPLE_SIZE 3006 | 171 | #define ERROR_HLS_AVC_SAMPLE_SIZE 3006 |
172 | #define ERROR_HTTP_PARSE_URI 3007 | 172 | #define ERROR_HTTP_PARSE_URI 3007 |
173 | -#define ERROR_HTTP_DATA_INVLIAD 3008 | 173 | +#define ERROR_HTTP_DATA_INVALID 3008 |
174 | #define ERROR_HTTP_PARSE_HEADER 3009 | 174 | #define ERROR_HTTP_PARSE_HEADER 3009 |
175 | #define ERROR_HTTP_HANDLER_MATCH_URL 3010 | 175 | #define ERROR_HTTP_HANDLER_MATCH_URL 3010 |
176 | #define ERROR_HTTP_HANDLER_INVALID 3011 | 176 | #define ERROR_HTTP_HANDLER_INVALID 3011 |
@@ -238,7 +238,7 @@ CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. | @@ -238,7 +238,7 @@ CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. | ||
238 | #define ERROR_HTTP_URL_NOT_CLEAN 4002 | 238 | #define ERROR_HTTP_URL_NOT_CLEAN 4002 |
239 | #define ERROR_HTTP_CONTENT_LENGTH 4003 | 239 | #define ERROR_HTTP_CONTENT_LENGTH 4003 |
240 | #define ERROR_HTTP_LIVE_STREAM_EXT 4004 | 240 | #define ERROR_HTTP_LIVE_STREAM_EXT 4004 |
241 | -#define ERROR_HTTP_STATUS_INVLIAD 4005 | 241 | +#define ERROR_HTTP_STATUS_INVALID 4005 |
242 | #define ERROR_KERNEL_AAC_STREAM_CLOSED 4006 | 242 | #define ERROR_KERNEL_AAC_STREAM_CLOSED 4006 |
243 | #define ERROR_AAC_DECODE_ERROR 4007 | 243 | #define ERROR_AAC_DECODE_ERROR 4007 |
244 | #define ERROR_KERNEL_MP3_STREAM_CLOSED 4008 | 244 | #define ERROR_KERNEL_MP3_STREAM_CLOSED 4008 |
-
请 注册 或 登录 后发表评论