Re: svn commit: r1913019 - in /httpd/httpd/trunk/modules/http2: h2_session.c h2_ws.c

2023-10-16 Thread Eric Covener
On Mon, Oct 16, 2023 at 9:13 AM Joe Orton  wrote:
>
> On Mon, Oct 16, 2023 at 02:54:58PM +0200, Ruediger Pluem wrote:
> > Fails for me as well. Not sure what fails for Joe such that he removed the 
> > include, but if it fails in case H2_USE_WEBSOCKETS is
> > not 1 I guess we could move the include (or even all) below the
> >
> > #if H2_USE_WEBSOCKETS
> >
> > line.
>
> Oh, sorry guys.
>
> I was building against APR 1.6.x here which doesn't have apr_encode.h, I
> didn't see the apr_pencode use. So how about:
>
> r1913019 + r1913023, +1 for 2.4.x for the pair
+1


Re: svn commit: r1913019 - in /httpd/httpd/trunk/modules/http2: h2_session.c h2_ws.c

2023-10-16 Thread Stefan Eissing via dev



> Am 16.10.2023 um 15:12 schrieb Joe Orton :
> 
> On Mon, Oct 16, 2023 at 02:54:58PM +0200, Ruediger Pluem wrote:
>> Fails for me as well. Not sure what fails for Joe such that he removed the 
>> include, but if it fails in case H2_USE_WEBSOCKETS is
>> not 1 I guess we could move the include (or even all) below the
>> 
>> #if H2_USE_WEBSOCKETS
>> 
>> line.
> 
> Oh, sorry guys. 
> 
> I was building against APR 1.6.x here which doesn't have apr_encode.h, I 
> didn't see the apr_pencode use. So how about:
> 
> r1913019 + r1913023, +1 for 2.4.x for the pair
> 

+1

Re: svn commit: r1913019 - in /httpd/httpd/trunk/modules/http2: h2_session.c h2_ws.c

2023-10-16 Thread Joe Orton
On Mon, Oct 16, 2023 at 02:54:58PM +0200, Ruediger Pluem wrote:
> Fails for me as well. Not sure what fails for Joe such that he removed the 
> include, but if it fails in case H2_USE_WEBSOCKETS is
> not 1 I guess we could move the include (or even all) below the
> 
> #if H2_USE_WEBSOCKETS
> 
> line.

Oh, sorry guys. 

I was building against APR 1.6.x here which doesn't have apr_encode.h, I 
didn't see the apr_pencode use. So how about:

r1913019 + r1913023, +1 for 2.4.x for the pair



Re: svn commit: r1913019 - in /httpd/httpd/trunk/modules/http2: h2_session.c h2_ws.c

2023-10-16 Thread Stefan Eissing via dev



> Am 16.10.2023 um 14:54 schrieb Ruediger Pluem :
> 
> 
> 
> On 10/16/23 2:38 PM, Stefan Eissing via dev wrote:
>> 
>> 
>>> Am 16.10.2023 um 14:28 schrieb jor...@apache.org:
>>> 
>>> Author: jorton
>>> Date: Mon Oct 16 12:28:13 2023
>>> New Revision: 1913019
>>> 
>>> URL: http://svn.apache.org/viewvc?rev=1913019=rev
>>> Log:
>>> Further h2 compile fixes:
>>> 
>>> * modules/http2/h2_session.c (h2_session_start):
>>> Restrict WebSockets options handling to with-WS builds.
>>> 
>>> * modules/http2/h2_ws.c: Don't include apr_encode.h (not used).
>>> 
>>> Modified:
>>>   httpd/httpd/trunk/modules/http2/h2_session.c
>>>   httpd/httpd/trunk/modules/http2/h2_ws.c
>>> 
>>> Modified: httpd/httpd/trunk/modules/http2/h2_session.c
>>> URL: 
>>> http://svn.apache.org/viewvc/httpd/httpd/trunk/modules/http2/h2_session.c?rev=1913019=1913018=1913019=diff
>>> ==
>>> --- httpd/httpd/trunk/modules/http2/h2_session.c (original)
>>> +++ httpd/httpd/trunk/modules/http2/h2_session.c Mon Oct 16 12:28:13 2023
>>> @@ -1085,11 +1085,13 @@ static apr_status_t h2_session_start(h2_
>>>settings[slen].value = win_size;
>>>++slen;
>>>}
>>> +#if H2_USE_WEBSOCKETS
>>>if (h2_config_sgeti(session->s, H2_CONF_WEBSOCKETS)) {
>>>  settings[slen].settings_id = NGHTTP2_SETTINGS_ENABLE_CONNECT_PROTOCOL;
>>>  settings[slen].value = 1;
>>>  ++slen;
>>>}
>>> +#endif
>>> 
>>>ap_log_cerror(APLOG_MARK, APLOG_DEBUG, status, session->c1,
>>>  H2_SSSN_LOG(APLOGNO(03201), session, 
>>> 
>> 
>> Fine.
>> 
>>> Modified: httpd/httpd/trunk/modules/http2/h2_ws.c
>>> URL: 
>>> http://svn.apache.org/viewvc/httpd/httpd/trunk/modules/http2/h2_ws.c?rev=1913019=1913018=1913019=diff
>>> ==
>>> --- httpd/httpd/trunk/modules/http2/h2_ws.c (original)
>>> +++ httpd/httpd/trunk/modules/http2/h2_ws.c Mon Oct 16 12:28:13 2023
>>> @@ -19,7 +19,6 @@
>>> #include "apr.h"
>>> #include "apr_strings.h"
>>> #include "apr_lib.h"
>>> -#include "apr_encode.h"
>>> #include "apr_sha1.h"
>>> #include "apr_strmatch.h"
>> 
>> Not working here:
>> h2_ws.c:70:12: error: call to undeclared function 
>> 'apr_pencode_base64_binary'; ISO C99 and later do not support implicit 
>> function declarations [-Wimplicit-function-declaration]
>>return apr_pencode_base64_binary(c->pool, dgst, sizeof(dgst),
>>   ^
>> h2_ws.c:71:38: error: use of undeclared identifier 'APR_ENCODE_NONE'
>> APR_ENCODE_NONE, NULL);
>> ^
>> h2_ws.c:123:18: error: call to undeclared function 
>> 'apr_pencode_base64_binary'; ISO C99 and later do not support implicit 
>> function declarations [-Wimplicit-function-declaration]
>>key_base64 = apr_pencode_base64_binary(c2->pool, key_raw, sizeof(key_raw),
>> ^
>> h2_ws.c:124:44: error: use of undeclared identifier 'APR_ENCODE_NONE'
>>   APR_ENCODE_NONE, NULL);
> 
> Fails for me as well. Not sure what fails for Joe such that he removed the 
> include, but if it fails in case H2_USE_WEBSOCKETS is
> not 1 I guess we could move the include (or even all) below the
> 
> #if H2_USE_WEBSOCKETS

It may be unnecessary without websockets, but how could it hurt?

> 
> line.
> 
> Regards
> 
> Rüdiger



Re: svn commit: r1913019 - in /httpd/httpd/trunk/modules/http2: h2_session.c h2_ws.c

2023-10-16 Thread Ruediger Pluem



On 10/16/23 2:38 PM, Stefan Eissing via dev wrote:
> 
> 
>> Am 16.10.2023 um 14:28 schrieb jor...@apache.org:
>>
>> Author: jorton
>> Date: Mon Oct 16 12:28:13 2023
>> New Revision: 1913019
>>
>> URL: http://svn.apache.org/viewvc?rev=1913019=rev
>> Log:
>> Further h2 compile fixes:
>>
>> * modules/http2/h2_session.c (h2_session_start):
>>  Restrict WebSockets options handling to with-WS builds.
>>
>> * modules/http2/h2_ws.c: Don't include apr_encode.h (not used).
>>
>> Modified:
>>httpd/httpd/trunk/modules/http2/h2_session.c
>>httpd/httpd/trunk/modules/http2/h2_ws.c
>>
>> Modified: httpd/httpd/trunk/modules/http2/h2_session.c
>> URL: 
>> http://svn.apache.org/viewvc/httpd/httpd/trunk/modules/http2/h2_session.c?rev=1913019=1913018=1913019=diff
>> ==
>> --- httpd/httpd/trunk/modules/http2/h2_session.c (original)
>> +++ httpd/httpd/trunk/modules/http2/h2_session.c Mon Oct 16 12:28:13 2023
>> @@ -1085,11 +1085,13 @@ static apr_status_t h2_session_start(h2_
>> settings[slen].value = win_size;
>> ++slen;
>> }
>> +#if H2_USE_WEBSOCKETS
>> if (h2_config_sgeti(session->s, H2_CONF_WEBSOCKETS)) {
>>   settings[slen].settings_id = NGHTTP2_SETTINGS_ENABLE_CONNECT_PROTOCOL;
>>   settings[slen].value = 1;
>>   ++slen;
>> }
>> +#endif
>>
>> ap_log_cerror(APLOG_MARK, APLOG_DEBUG, status, session->c1,
>>   H2_SSSN_LOG(APLOGNO(03201), session, 
>>
> 
> Fine.
> 
>> Modified: httpd/httpd/trunk/modules/http2/h2_ws.c
>> URL: 
>> http://svn.apache.org/viewvc/httpd/httpd/trunk/modules/http2/h2_ws.c?rev=1913019=1913018=1913019=diff
>> ==
>> --- httpd/httpd/trunk/modules/http2/h2_ws.c (original)
>> +++ httpd/httpd/trunk/modules/http2/h2_ws.c Mon Oct 16 12:28:13 2023
>> @@ -19,7 +19,6 @@
>> #include "apr.h"
>> #include "apr_strings.h"
>> #include "apr_lib.h"
>> -#include "apr_encode.h"
>> #include "apr_sha1.h"
>> #include "apr_strmatch.h"
> 
> Not working here:
> h2_ws.c:70:12: error: call to undeclared function 
> 'apr_pencode_base64_binary'; ISO C99 and later do not support implicit 
> function declarations [-Wimplicit-function-declaration]
> return apr_pencode_base64_binary(c->pool, dgst, sizeof(dgst),
>^
> h2_ws.c:71:38: error: use of undeclared identifier 'APR_ENCODE_NONE'
>  APR_ENCODE_NONE, NULL);
>  ^
> h2_ws.c:123:18: error: call to undeclared function 
> 'apr_pencode_base64_binary'; ISO C99 and later do not support implicit 
> function declarations [-Wimplicit-function-declaration]
> key_base64 = apr_pencode_base64_binary(c2->pool, key_raw, sizeof(key_raw),
>  ^
> h2_ws.c:124:44: error: use of undeclared identifier 'APR_ENCODE_NONE'
>APR_ENCODE_NONE, NULL);

Fails for me as well. Not sure what fails for Joe such that he removed the 
include, but if it fails in case H2_USE_WEBSOCKETS is
not 1 I guess we could move the include (or even all) below the

#if H2_USE_WEBSOCKETS

line.

Regards

Rüdiger


Re: svn commit: r1913019 - in /httpd/httpd/trunk/modules/http2: h2_session.c h2_ws.c

2023-10-16 Thread Stefan Eissing via dev



> Am 16.10.2023 um 14:28 schrieb jor...@apache.org:
> 
> Author: jorton
> Date: Mon Oct 16 12:28:13 2023
> New Revision: 1913019
> 
> URL: http://svn.apache.org/viewvc?rev=1913019=rev
> Log:
> Further h2 compile fixes:
> 
> * modules/http2/h2_session.c (h2_session_start):
>  Restrict WebSockets options handling to with-WS builds.
> 
> * modules/http2/h2_ws.c: Don't include apr_encode.h (not used).
> 
> Modified:
>httpd/httpd/trunk/modules/http2/h2_session.c
>httpd/httpd/trunk/modules/http2/h2_ws.c
> 
> Modified: httpd/httpd/trunk/modules/http2/h2_session.c
> URL: 
> http://svn.apache.org/viewvc/httpd/httpd/trunk/modules/http2/h2_session.c?rev=1913019=1913018=1913019=diff
> ==
> --- httpd/httpd/trunk/modules/http2/h2_session.c (original)
> +++ httpd/httpd/trunk/modules/http2/h2_session.c Mon Oct 16 12:28:13 2023
> @@ -1085,11 +1085,13 @@ static apr_status_t h2_session_start(h2_
> settings[slen].value = win_size;
> ++slen;
> }
> +#if H2_USE_WEBSOCKETS
> if (h2_config_sgeti(session->s, H2_CONF_WEBSOCKETS)) {
>   settings[slen].settings_id = NGHTTP2_SETTINGS_ENABLE_CONNECT_PROTOCOL;
>   settings[slen].value = 1;
>   ++slen;
> }
> +#endif
> 
> ap_log_cerror(APLOG_MARK, APLOG_DEBUG, status, session->c1,
>   H2_SSSN_LOG(APLOGNO(03201), session, 
> 

Fine.

> Modified: httpd/httpd/trunk/modules/http2/h2_ws.c
> URL: 
> http://svn.apache.org/viewvc/httpd/httpd/trunk/modules/http2/h2_ws.c?rev=1913019=1913018=1913019=diff
> ==
> --- httpd/httpd/trunk/modules/http2/h2_ws.c (original)
> +++ httpd/httpd/trunk/modules/http2/h2_ws.c Mon Oct 16 12:28:13 2023
> @@ -19,7 +19,6 @@
> #include "apr.h"
> #include "apr_strings.h"
> #include "apr_lib.h"
> -#include "apr_encode.h"
> #include "apr_sha1.h"
> #include "apr_strmatch.h"

Not working here:
h2_ws.c:70:12: error: call to undeclared function 'apr_pencode_base64_binary'; 
ISO C99 and later do not support implicit function declarations 
[-Wimplicit-function-declaration]
return apr_pencode_base64_binary(c->pool, dgst, sizeof(dgst),
   ^
h2_ws.c:71:38: error: use of undeclared identifier 'APR_ENCODE_NONE'
 APR_ENCODE_NONE, NULL);
 ^
h2_ws.c:123:18: error: call to undeclared function 'apr_pencode_base64_binary'; 
ISO C99 and later do not support implicit function declarations 
[-Wimplicit-function-declaration]
key_base64 = apr_pencode_base64_binary(c2->pool, key_raw, sizeof(key_raw),
 ^
h2_ws.c:124:44: error: use of undeclared identifier 'APR_ENCODE_NONE'
   APR_ENCODE_NONE, NULL);