comparison src/core/ngx_string.c @ 274:052a7b1d40e5 NGINX_0_5_7

nginx 0.5.7 *) Feature: the ssl_session_cache storage optimization. *) Bugfixes in the "ssl_session_cache" and "limit_zone" directives. *) Bugfix: the segmentation fault was occurred on start or while reconfiguration if the "ssl_session_cache" or "limit_zone" directives were used on 64-bit platforms. *) Bugfix: a segmentation fault occurred if the "add_before_body" or "add_after_body" directives were used and there was no "Content-Type" header line in response. *) Bugfix: the OpenSSL library was always built with the threads support. Thanks to Den Ivanov. *) Bugfix: the PCRE-6.5+ library and the icc compiler compatibility.
author Igor Sysoev <http://sysoev.ru>
date Mon, 15 Jan 2007 00:00:00 +0300
parents f3ec44f4a53b
children 5bef04fc3fd5
comparison
equal deleted inserted replaced
273:60df8db42ffb 274:052a7b1d40e5
485 } 485 }
486 } 486 }
487 487
488 488
489 ngx_int_t 489 ngx_int_t
490 ngx_memn2cmp(u_char *s1, u_char *s2, size_t n1, size_t n2)
491 {
492 size_t n;
493 ngx_int_t m, z;
494
495 if (n1 <= n2) {
496 n = n1;
497 z = -1;
498
499 } else {
500 n = n2;
501 z = 1;
502 }
503
504 m = ngx_memcmp(s1, s2, n);
505
506 if (m || n1 == n2) {
507 return m;
508 }
509
510 return z;
511 }
512
513
514 ngx_int_t
490 ngx_atoi(u_char *line, size_t n) 515 ngx_atoi(u_char *line, size_t n)
491 { 516 {
492 ngx_int_t value; 517 ngx_int_t value;
493 518
494 if (n == 0) { 519 if (n == 0) {