winlin

merge srs2, use specific error code for dns resolve

@@ -206,6 +206,7 @@ Please select your language: @@ -206,6 +206,7 @@ Please select your language:
206 206
207 ### V2 changes 207 ### V2 changes
208 208
  209 +* v2.0, 2017-01-18, fix [#750][bug #750] use specific error code for dns resolve. 2.0.231
209 * <strong>v2.0, 2017-01-18, [2.0 beta4(2.0.230)][r2.0b4] released. 86334 lines.</strong> 210 * <strong>v2.0, 2017-01-18, [2.0 beta4(2.0.230)][r2.0b4] released. 86334 lines.</strong>
210 * v2.0, 2017-01-18, fix [#749][bug #749], timestamp overflow for ATC. 2.0.230 211 * v2.0, 2017-01-18, fix [#749][bug #749], timestamp overflow for ATC. 2.0.230
211 * v2.0, 2017-01-11, fix [#740][bug #740], convert ts aac audio private stream 1 to common. 2.0.229 212 * v2.0, 2017-01-11, fix [#740][bug #740], convert ts aac audio private stream 1 to common. 2.0.229
@@ -104,6 +104,7 @@ CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. @@ -104,6 +104,7 @@ CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
104 #define ERROR_SYSTEM_CONFIG_RAW_PARAMS 1063 104 #define ERROR_SYSTEM_CONFIG_RAW_PARAMS 1063
105 #define ERROR_SYSTEM_FILE_NOT_EXISTS 1064 105 #define ERROR_SYSTEM_FILE_NOT_EXISTS 1064
106 #define ERROR_SYSTEM_HOURGLASS_RESOLUTION 1065 106 #define ERROR_SYSTEM_HOURGLASS_RESOLUTION 1065
  107 +#define ERROR_SYSTEM_DNS_RESOLVE 1066
107 108
108 /////////////////////////////////////////////////////// 109 ///////////////////////////////////////////////////////
109 // RTMP protocol error. 110 // RTMP protocol error.
@@ -491,7 +491,7 @@ int srs_librtmp_context_resolve_host(Context* context) @@ -491,7 +491,7 @@ int srs_librtmp_context_resolve_host(Context* context)
491 // connect to server:port 491 // connect to server:port
492 context->ip = srs_dns_resolve(context->host); 492 context->ip = srs_dns_resolve(context->host);
493 if (context->ip.empty()) { 493 if (context->ip.empty()) {
494 - return -1; 494 + return ERROR_SYSTEM_DNS_RESOLVE;
495 } 495 }
496 496
497 return ret; 497 return ret;