@@ -875,7 +875,7 @@ psync_http_socket *psync_http_connect(const char *host, const char *path, uint64
875
875
char ch , lch ;
876
876
char cachekey [256 ];
877
877
usessl = psync_setting_get_bool (_PS (usessl ));
878
- cl = snprintf (cachekey , sizeof (cachekey )- 1 , "HT %d-%s" , usessl , host )+ 1 ;
878
+ cl = snprintf (cachekey , sizeof (cachekey )- 1 , "HTTP %d-%s" , usessl , host )+ 1 ;
879
879
cachekey [sizeof (cachekey )- 1 ]= 0 ;
880
880
sock = (psync_socket * )psync_cache_get (cachekey );
881
881
if (!sock ){
@@ -1067,7 +1067,7 @@ static void connect_cache_thread(void *ptr){
1067
1067
else {
1068
1068
if (sock ){
1069
1069
char cachekey [256 ];
1070
- snprintf (cachekey , sizeof (cachekey )- 1 , "HT %d-%s" , node -> usessl , node -> host );
1070
+ snprintf (cachekey , sizeof (cachekey )- 1 , "HTTP %d-%s" , node -> usessl , node -> host );
1071
1071
cachekey [sizeof (cachekey )- 1 ]= 0 ;
1072
1072
psync_cache_add (cachekey , sock , 25 , (psync_cache_free_callback )psync_socket_close_download , PSYNC_MAX_IDLE_HTTP_CONNS );
1073
1073
}
@@ -1224,7 +1224,7 @@ psync_http_socket *psync_http_connect_multihost(const binresult *hosts, const ch
1224
1224
usessl = psync_setting_get_bool (_PS (usessl ));
1225
1225
sock = NULL ;
1226
1226
for (i = 0 ; i < hosts -> length ; i ++ ){
1227
- cl = snprintf (cachekey , sizeof (cachekey )- 1 , "HT %d-%s" , usessl , hosts -> array [i ]-> str )+ 1 ;
1227
+ cl = snprintf (cachekey , sizeof (cachekey )- 1 , "HTTP %d-%s" , usessl , hosts -> array [i ]-> str )+ 1 ;
1228
1228
cachekey [sizeof (cachekey )- 1 ]= 0 ;
1229
1229
sock = (psync_socket * )psync_cache_get (cachekey );
1230
1230
if (sock ){
@@ -1242,7 +1242,7 @@ psync_http_socket *psync_http_connect_multihost(const binresult *hosts, const ch
1242
1242
if (!sock ){
1243
1243
for (i = 0 ; i < hosts -> length ; i ++ )
1244
1244
if ((sock = connect_cache_wait_for_http_connection (hosts -> array [i ]-> str , usessl ))){
1245
- cl = snprintf (cachekey , sizeof (cachekey )- 1 , "HT %d-%s" , usessl , hosts -> array [i ]-> str )+ 1 ;
1245
+ cl = snprintf (cachekey , sizeof (cachekey )- 1 , "HTTP %d-%s" , usessl , hosts -> array [i ]-> str )+ 1 ;
1246
1246
cachekey [sizeof (cachekey )- 1 ]= 0 ;
1247
1247
* host = hosts -> array [i ]-> str ;
1248
1248
break ;
@@ -1251,7 +1251,7 @@ psync_http_socket *psync_http_connect_multihost(const binresult *hosts, const ch
1251
1251
for (i = 0 ; i < hosts -> length ; i ++ ){
1252
1252
sock = psync_socket_connect (hosts -> array [i ]-> str , usessl ?443 :80 , usessl );
1253
1253
if (sock ){
1254
- cl = snprintf (cachekey , sizeof (cachekey )- 1 , "HT %d-%s" , usessl , hosts -> array [i ]-> str )+ 1 ;
1254
+ cl = snprintf (cachekey , sizeof (cachekey )- 1 , "HTTP %d-%s" , usessl , hosts -> array [i ]-> str )+ 1 ;
1255
1255
cachekey [sizeof (cachekey )- 1 ]= 0 ;
1256
1256
* host = hosts -> array [i ]-> str ;
1257
1257
break ;
@@ -1284,7 +1284,7 @@ psync_http_socket *psync_http_connect_multihost_from_cache(const binresult *host
1284
1284
usessl = psync_setting_get_bool (_PS (usessl ));
1285
1285
sock = NULL ;
1286
1286
for (i = 0 ; i < hosts -> length ; i ++ ){
1287
- cl = snprintf (cachekey , sizeof (cachekey )- 1 , "HT %d-%s" , usessl , hosts -> array [i ]-> str )+ 1 ;
1287
+ cl = snprintf (cachekey , sizeof (cachekey )- 1 , "HTTP %d-%s" , usessl , hosts -> array [i ]-> str )+ 1 ;
1288
1288
cachekey [sizeof (cachekey )- 1 ]= 0 ;
1289
1289
sock = (psync_socket * )psync_cache_get (cachekey );
1290
1290
if (sock ){
0 commit comments