winlin

fix #750, use specific error code for dns resolve. 2.0.231

@@ -346,6 +346,7 @@ Remark: @@ -346,6 +346,7 @@ Remark:
346 346
347 ## History 347 ## History
348 348
  349 +* v2.0, 2017-01-18, fix [#750][bug #750] use specific error code for dns resolve. 2.0.231
349 * <strong>v2.0, 2017-01-18, [2.0 beta4(2.0.230)][r2.0b4] released. 86334 lines.</strong> 350 * <strong>v2.0, 2017-01-18, [2.0 beta4(2.0.230)][r2.0b4] released. 86334 lines.</strong>
350 * v2.0, 2017-01-18, fix [#749][bug #749], timestamp overflow for ATC. 2.0.230 351 * v2.0, 2017-01-18, fix [#749][bug #749], timestamp overflow for ATC. 2.0.230
351 * v2.0, 2017-01-11, fix [#740][bug #740], convert ts aac audio private stream 1 to common. 2.0.229 352 * v2.0, 2017-01-11, fix [#740][bug #740], convert ts aac audio private stream 1 to common. 2.0.229
@@ -31,7 +31,7 @@ CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. @@ -31,7 +31,7 @@ CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
31 // current release version 31 // current release version
32 #define VERSION_MAJOR 2 32 #define VERSION_MAJOR 2
33 #define VERSION_MINOR 0 33 #define VERSION_MINOR 0
34 -#define VERSION_REVISION 230 34 +#define VERSION_REVISION 231
35 35
36 // generated by configure, only macros. 36 // generated by configure, only macros.
37 #include <srs_auto_headers.hpp> 37 #include <srs_auto_headers.hpp>
@@ -97,6 +97,7 @@ CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. @@ -97,6 +97,7 @@ CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
97 #define ERROR_SYSTEM_DIR_EXISTS 1056 97 #define ERROR_SYSTEM_DIR_EXISTS 1056
98 #define ERROR_SYSTEM_CREATE_DIR 1057 98 #define ERROR_SYSTEM_CREATE_DIR 1057
99 #define ERROR_SYSTEM_KILL 1058 99 #define ERROR_SYSTEM_KILL 1058
  100 +#define ERROR_SYSTEM_DNS_RESOLVE 1059
100 101
101 /////////////////////////////////////////////////////// 102 ///////////////////////////////////////////////////////
102 // RTMP protocol error. 103 // RTMP protocol error.
@@ -495,7 +495,7 @@ int srs_librtmp_context_resolve_host(Context* context) @@ -495,7 +495,7 @@ int srs_librtmp_context_resolve_host(Context* context)
495 // connect to server:port 495 // connect to server:port
496 context->ip = srs_dns_resolve(context->host); 496 context->ip = srs_dns_resolve(context->host);
497 if (context->ip.empty()) { 497 if (context->ip.empty()) {
498 - return -1; 498 + return ERROR_SYSTEM_DNS_RESOLVE;
499 } 499 }
500 500
501 return ret; 501 return ret;