@@ -82,6 +82,7 @@ public HttpResult Get(string url, string token, bool binaryMode = false)
8282 }
8383 wReq . UserAgent = userAgent ;
8484 wReq . AllowAutoRedirect = allowAutoRedirect ;
85+ wReq . ServicePoint . Expect100Continue = false ;
8586
8687 HttpWebResponse wResp = wReq . GetResponse ( ) as HttpWebResponse ;
8788
@@ -149,7 +150,7 @@ public HttpResult Get(string url, string token, bool binaryMode = false)
149150 }
150151 sb . AppendLine ( ) ;
151152
152- result . RefCode = ( int ) HttpCode . USER_EXCEPTION ;
153+ result . RefCode = ( int ) HttpCode . USER_UNDEF ;
153154 result . RefText += sb . ToString ( ) ;
154155 }
155156 finally
@@ -186,6 +187,7 @@ public HttpResult Post(string url, string token, bool binaryMode = false)
186187 }
187188 wReq . UserAgent = userAgent ;
188189 wReq . AllowAutoRedirect = allowAutoRedirect ;
190+ wReq . ServicePoint . Expect100Continue = false ;
189191
190192 HttpWebResponse wResp = wReq . GetResponse ( ) as HttpWebResponse ;
191193
@@ -253,7 +255,7 @@ public HttpResult Post(string url, string token, bool binaryMode = false)
253255 }
254256 sb . AppendLine ( ) ;
255257
256- result . RefCode = ( int ) HttpCode . USER_EXCEPTION ;
258+ result . RefCode = ( int ) HttpCode . USER_UNDEF ;
257259 result . RefText += sb . ToString ( ) ;
258260 }
259261 finally
@@ -292,6 +294,7 @@ public HttpResult PostData(string url, byte[] data, string token, bool binaryMod
292294 wReq . ContentType = ContentType . APPLICATION_OCTET_STREAM ;
293295 wReq . UserAgent = userAgent ;
294296 wReq . AllowAutoRedirect = allowAutoRedirect ;
297+ wReq . ServicePoint . Expect100Continue = false ;
295298
296299 if ( data != null )
297300 {
@@ -369,7 +372,7 @@ public HttpResult PostData(string url, byte[] data, string token, bool binaryMod
369372 }
370373 sb . AppendLine ( ) ;
371374
372- result . RefCode = ( int ) HttpCode . USER_EXCEPTION ;
375+ result . RefCode = ( int ) HttpCode . USER_UNDEF ;
373376 result . RefText += sb . ToString ( ) ;
374377 }
375378 finally
@@ -409,6 +412,7 @@ public HttpResult PostData(string url, byte[] data, string mimeType, string toke
409412 wReq . ContentType = mimeType ;
410413 wReq . UserAgent = userAgent ;
411414 wReq . AllowAutoRedirect = allowAutoRedirect ;
415+ wReq . ServicePoint . Expect100Continue = false ;
412416
413417 if ( data != null )
414418 {
@@ -486,7 +490,7 @@ public HttpResult PostData(string url, byte[] data, string mimeType, string toke
486490 }
487491 sb . AppendLine ( ) ;
488492
489- result . RefCode = ( int ) HttpCode . USER_EXCEPTION ;
493+ result . RefCode = ( int ) HttpCode . USER_UNDEF ;
490494 result . RefText += sb . ToString ( ) ;
491495 }
492496 finally
@@ -525,6 +529,7 @@ public HttpResult PostJson(string url, string data, string token, bool binaryMod
525529 wReq . ContentType = ContentType . APPLICATION_JSON ;
526530 wReq . UserAgent = userAgent ;
527531 wReq . AllowAutoRedirect = allowAutoRedirect ;
532+ wReq . ServicePoint . Expect100Continue = false ;
528533
529534 if ( data != null )
530535 {
@@ -602,7 +607,7 @@ public HttpResult PostJson(string url, string data, string token, bool binaryMod
602607 }
603608 sb . AppendLine ( ) ;
604609
605- result . RefCode = ( int ) HttpCode . USER_EXCEPTION ;
610+ result . RefCode = ( int ) HttpCode . USER_UNDEF ;
606611 result . RefText += sb . ToString ( ) ;
607612 }
608613 finally
@@ -641,6 +646,7 @@ public HttpResult PostText(string url, string data, string token, bool binaryMod
641646 wReq . ContentType = ContentType . TEXT_PLAIN ;
642647 wReq . UserAgent = userAgent ;
643648 wReq . AllowAutoRedirect = allowAutoRedirect ;
649+ wReq . ServicePoint . Expect100Continue = false ;
644650
645651 if ( data != null )
646652 {
@@ -718,7 +724,7 @@ public HttpResult PostText(string url, string data, string token, bool binaryMod
718724 }
719725 sb . AppendLine ( ) ;
720726
721- result . RefCode = ( int ) HttpCode . USER_EXCEPTION ;
727+ result . RefCode = ( int ) HttpCode . USER_UNDEF ;
722728 result . RefText += sb . ToString ( ) ;
723729 }
724730 finally
@@ -757,6 +763,7 @@ public HttpResult PostForm(string url, Dictionary<string, string> kvData, string
757763 wReq . ContentType = ContentType . WWW_FORM_URLENC ;
758764 wReq . UserAgent = userAgent ;
759765 wReq . AllowAutoRedirect = allowAutoRedirect ;
766+ wReq . ServicePoint . Expect100Continue = false ;
760767
761768 if ( kvData != null )
762769 {
@@ -840,7 +847,7 @@ public HttpResult PostForm(string url, Dictionary<string, string> kvData, string
840847 }
841848 sb . AppendLine ( ) ;
842849
843- result . RefCode = ( int ) HttpCode . USER_EXCEPTION ;
850+ result . RefCode = ( int ) HttpCode . USER_UNDEF ;
844851 result . RefText += sb . ToString ( ) ;
845852 }
846853 finally
@@ -879,6 +886,7 @@ public HttpResult PostForm(string url, string data, string token, bool binaryMod
879886 wReq . ContentType = ContentType . WWW_FORM_URLENC ;
880887 wReq . UserAgent = userAgent ;
881888 wReq . AllowAutoRedirect = allowAutoRedirect ;
889+ wReq . ServicePoint . Expect100Continue = false ;
882890
883891 if ( ! string . IsNullOrEmpty ( data ) )
884892 {
@@ -956,7 +964,7 @@ public HttpResult PostForm(string url, string data, string token, bool binaryMod
956964 }
957965 sb . AppendLine ( ) ;
958966
959- result . RefCode = ( int ) HttpCode . USER_EXCEPTION ;
967+ result . RefCode = ( int ) HttpCode . USER_UNDEF ;
960968 result . RefText += sb . ToString ( ) ;
961969 }
962970 finally
@@ -995,6 +1003,7 @@ public HttpResult PostForm(string url, byte[] data, string token, bool binaryMod
9951003 wReq . ContentType = ContentType . WWW_FORM_URLENC ;
9961004 wReq . UserAgent = userAgent ;
9971005 wReq . AllowAutoRedirect = allowAutoRedirect ;
1006+ wReq . ServicePoint . Expect100Continue = false ;
9981007
9991008 if ( data != null )
10001009 {
@@ -1072,7 +1081,7 @@ public HttpResult PostForm(string url, byte[] data, string token, bool binaryMod
10721081 }
10731082 sb . AppendLine ( ) ;
10741083
1075- result . RefCode = ( int ) HttpCode . USER_EXCEPTION ;
1084+ result . RefCode = ( int ) HttpCode . USER_UNDEF ;
10761085 result . RefText += sb . ToString ( ) ;
10771086 }
10781087 finally
@@ -1112,6 +1121,7 @@ public HttpResult PostMultipart(string url, byte[] data, string boundary, string
11121121 wReq . ContentType = string . Format ( "{0}; boundary={1}" , ContentType . MULTIPART_FORM_DATA , boundary ) ;
11131122 wReq . UserAgent = userAgent ;
11141123 wReq . AllowAutoRedirect = allowAutoRedirect ;
1124+ wReq . ServicePoint . Expect100Continue = false ;
11151125
11161126 wReq . AllowWriteStreamBuffering = true ;
11171127 using ( Stream sReq = wReq . GetRequestStream ( ) )
@@ -1186,7 +1196,7 @@ public HttpResult PostMultipart(string url, byte[] data, string boundary, string
11861196 }
11871197 sb . AppendLine ( ) ;
11881198
1189- result . RefCode = ( int ) HttpCode . USER_EXCEPTION ;
1199+ result . RefCode = ( int ) HttpCode . USER_UNDEF ;
11901200 result . RefText += sb . ToString ( ) ;
11911201 }
11921202 finally
0 commit comments