diff src/mail/ngx_mail_auth_http_module.c @ 635:e67b227c8dbb default tip

Merge with current.
author Maxim Dounin <mdounin@mdounin.ru>
date Mon, 25 Apr 2011 04:07:55 +0400
parents 8246d8a2c2be
children
line wrap: on
line diff
--- a/src/mail/ngx_mail_auth_http_module.c
+++ b/src/mail/ngx_mail_auth_http_module.c
@@ -1409,15 +1409,13 @@ ngx_mail_auth_http(ngx_conf_t *cf, ngx_c
         ahcf->host_header = u.host;
 
     } else {
-        ahcf->host_header.len = sizeof("localhost") - 1;
-        ahcf->host_header.data = (u_char *) "localhost";
+        ngx_str_set(&ahcf->host_header, "localhost");
     }
 
     ahcf->uri = u.uri;
 
     if (ahcf->uri.len == 0) {
-        ahcf->uri.len = sizeof("/") - 1;
-        ahcf->uri.data = (u_char *) "/";
+        ngx_str_set(&ahcf->uri, "/");
     }
 
     return NGX_CONF_OK;