diff options
author | Jay Satiro <raysatiro@yahoo.com> | 2015-06-30 17:19:21 -0400 |
---|---|---|
committer | Jay Satiro <raysatiro@yahoo.com> | 2015-06-30 17:19:21 -0400 |
commit | 66a5f76583d3163ecdd00a3c2a43e1a243eee193 (patch) | |
tree | 7b6b895de5d9d82a1e8cbf2ec0075a80043f3ee8 | |
parent | 616cecfdb6b377b7920f4b6bfe1bb775463c7f73 (diff) |
multi: Move http2 push function declarations to header end
This change necessary for binary compatibility.
Prior to this change test 1135 failed due to the order of functions.
-rw-r--r-- | include/curl/multi.h | 49 | ||||
-rw-r--r-- | tests/data/test1135 | 2 |
2 files changed, 27 insertions, 24 deletions
diff --git a/include/curl/multi.h b/include/curl/multi.h index d34694c4c..36e2e940e 100644 --- a/include/curl/multi.h +++ b/include/curl/multi.h @@ -283,30 +283,6 @@ typedef int (*curl_multi_timer_callback)(CURLM *multi, /* multi handle */ void *userp); /* private callback pointer */ -/* - * Name: curl_push_callback - * - * Desc: This callback gets called when a new stream is being pushed by the - * server. It approves or denies the new stream. - * - * Returns: CURL_PUSH_OK or CURL_PUSH_DENY. - */ -#define CURL_PUSH_OK 0 -#define CURL_PUSH_DENY 1 - -struct curl_pushheaders; /* forward declaration only */ - -CURL_EXTERN char *curl_pushheader_bynum(struct curl_pushheaders *h, - size_t num); -CURL_EXTERN char *curl_pushheader_byname(struct curl_pushheaders *h, - const char *name); - -typedef int (*curl_push_callback)(CURL *parent, - CURL *easy, - size_t num_headers, - struct curl_pushheaders *headers, - void *userp); - CURL_EXTERN CURLMcode curl_multi_socket(CURLM *multi_handle, curl_socket_t s, int *running_handles); @@ -427,6 +403,31 @@ CURL_EXTERN CURLMcode curl_multi_setopt(CURLM *multi_handle, CURL_EXTERN CURLMcode curl_multi_assign(CURLM *multi_handle, curl_socket_t sockfd, void *sockp); + +/* + * Name: curl_push_callback + * + * Desc: This callback gets called when a new stream is being pushed by the + * server. It approves or denies the new stream. + * + * Returns: CURL_PUSH_OK or CURL_PUSH_DENY. + */ +#define CURL_PUSH_OK 0 +#define CURL_PUSH_DENY 1 + +struct curl_pushheaders; /* forward declaration only */ + +CURL_EXTERN char *curl_pushheader_bynum(struct curl_pushheaders *h, + size_t num); +CURL_EXTERN char *curl_pushheader_byname(struct curl_pushheaders *h, + const char *name); + +typedef int (*curl_push_callback)(CURL *parent, + CURL *easy, + size_t num_headers, + struct curl_pushheaders *headers, + void *userp); + #ifdef __cplusplus } /* end of extern "C" */ #endif diff --git a/tests/data/test1135 b/tests/data/test1135 index 8fce5658a..960aade8d 100644 --- a/tests/data/test1135 +++ b/tests/data/test1135 @@ -87,6 +87,8 @@ CURL_EXTERN CURLMcode curl_multi_socket_all(CURLM *multi_handle, CURL_EXTERN CURLMcode curl_multi_timeout(CURLM *multi_handle, CURL_EXTERN CURLMcode curl_multi_setopt(CURLM *multi_handle, CURL_EXTERN CURLMcode curl_multi_assign(CURLM *multi_handle, +CURL_EXTERN char *curl_pushheader_bynum(struct curl_pushheaders *h, +CURL_EXTERN char *curl_pushheader_byname(struct curl_pushheaders *h, </stdout> </verify> |