Welcome! Log In Create A New Profile

Advanced

Re: NGINX 1.0.3 compile error: src/core/ngx_crypt.c: In function ‘ngx_crypt_apr1’

All files from this thread

File Name File Size   Posted by Date  
1.9 KB open | download Dalibor Jotanovic 05/27/2011 Read message
1.1 KB open | download Dalibor Jotanovic 05/27/2011 Read message
1.9 KB open | download Dalibor Jotanovic 05/27/2011 Read message
1.1 KB open | download Dalibor Jotanovic 05/27/2011 Read message
May 27, 2011 05:58AM
On Fri, May 27, 2011 at 11:30:17AM +0200, Dalibor Jotanovic wrote:
> Hi,
>
> i'm having problems compiling the latest stable source 1.0.3.
>
> How to reproduce:
>
> cd <sourcedirectory>
> ./configure
> make
>
> make output is attached in log.txt
>
> I do not have any problems compiling stable source 1.0.2
>
> Is suspect this issue beeing a bug. Can somebody confirm this?

> gcc -c -pipe -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Wunused-function -Wunused-variable -Wunused-value -Werror -g -I src/core -I
> src/event -I src/event/modules -I src/os/unix -I objs \
> -o objs/src/core/ngx_crypt.o \
> src/core/ngx_crypt.c
> cc1: warnings being treated as errors
> src/core/ngx_crypt.c: In function Б─≤ngx_crypt_apr1Б─≥:
> src/core/ngx_crypt.c:76: warning: pointer targets in passing argument 2 of Б─≤ngx_md5_updateБ─≥ differ in signedness

Thank you for the report.
The attached patch should fix the issue.


--
Igor Sysoev
Index: src/core/ngx_md5.c
===================================================================
--- src/core/ngx_md5.c (revision 3927)
+++ src/core/ngx_md5.c (working copy)
@@ -32,7 +32,7 @@


void
-ngx_md5_update(ngx_md5_t *ctx, const u_char *data, size_t size)
+ngx_md5_update(ngx_md5_t *ctx, const void *data, size_t size)
{
size_t used, free;

@@ -47,8 +47,7 @@
return;
}

- ngx_memcpy(&ctx->buffer[used], data, free);
- data = (u_char *)data + free;
+ data = ngx_cpymem(&ctx->buffer[used], data, free);
size -= free;
(void) ngx_md5_body(ctx, ctx->buffer, 64);
}
Index: src/core/ngx_md5.h
===================================================================
--- src/core/ngx_md5.h (revision 3927)
+++ src/core/ngx_md5.h (working copy)
@@ -50,7 +50,7 @@


void ngx_md5_init(ngx_md5_t *ctx);
-void ngx_md5_update(ngx_md5_t *ctx, const u_char *data, size_t size);
+void ngx_md5_update(ngx_md5_t *ctx, const void *data, size_t size);
void ngx_md5_final(u_char result[16], ngx_md5_t *ctx);


_______________________________________________
nginx mailing list
nginx@nginx.org
http://nginx.org/mailman/listinfo/nginx
Subject Author Posted

NGINX 1.0.3 compile error: src/core/ngx_crypt.c: In function ‘ngx_crypt_apr1’ Attachments

Dalibor Jotanovic May 27, 2011 05:32AM

Re: NGINX 1.0.3 compile error: src/core/ngx_crypt.c: In function ‘ngx_crypt_apr1’

Igor Sysoev May 27, 2011 05:58AM

Antw: Re: NGINX 1.0.3 compile error: src/core/ngx_crypt.c: In function ‘ngx_crypt_apr1’ Attachments

Dalibor Jotanovic May 27, 2011 06:40AM

Re: NGINX 1.0.3 compile error: src/core/ngx_crypt.c: In function ‘ngx_crypt_apr1’

Maxim Dounin May 27, 2011 08:08AM

Re: NGINX 1.0.3 compile error: src/core/ngx_crypt.c: In function ‘ngx_crypt_apr1’

Igor Sysoev May 27, 2011 08:20AM

Re: NGINX 1.0.3 compile error: src/core/ngx_crypt.c: In function ‘ngx_crypt_apr1’

Igor Sysoev May 27, 2011 08:36AM

Re: NGINX 1.0.3 compile error: src/core/ngx_crypt.c: In function ‘ngx_crypt_apr1’

Maxim Dounin May 27, 2011 08:38AM



Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 181
Record Number of Users: 8 on April 13, 2023
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready