diff options
| author | Garrett D'Amore <garrett@damore.org> | 2024-12-22 11:40:36 -0800 |
|---|---|---|
| committer | Garrett D'Amore <garrett@damore.org> | 2024-12-22 11:40:36 -0800 |
| commit | 8d1b52931b1d7ad8fabffe0098b9bc31c0b61a9b (patch) | |
| tree | b6bf2966a0fa4dbabcd06bdaf0135776f11f6563 /src/supplemental/http/http_public.c | |
| parent | 6800bdd8b9e3fd4488bab56cd9fb12206d0631f6 (diff) | |
| download | nng-8d1b52931b1d7ad8fabffe0098b9bc31c0b61a9b.tar.gz nng-8d1b52931b1d7ad8fabffe0098b9bc31c0b61a9b.tar.bz2 nng-8d1b52931b1d7ad8fabffe0098b9bc31c0b61a9b.zip | |
http: method on request structure is now static
This saves yet another allocation. It also no longer returns a value
making this a breaking change.
Diffstat (limited to 'src/supplemental/http/http_public.c')
| -rw-r--r-- | src/supplemental/http/http_public.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/src/supplemental/http/http_public.c b/src/supplemental/http/http_public.c index 161aefd8..c9983df5 100644 --- a/src/supplemental/http/http_public.c +++ b/src/supplemental/http/http_public.c @@ -280,15 +280,14 @@ nng_http_req_get_uri(const nng_http_req *req) #endif } -int +void nng_http_req_set_method(nng_http_req *req, const char *meth) { #ifdef NNG_SUPP_HTTP - return (nni_http_req_set_method(req, meth)); + nni_http_req_set_method(req, meth); #else NNI_ARG_UNUSED(req); NNI_ARG_UNUSED(meth); - return (NNG_ENOTSUP); #endif } |
