]> git.kaiwu.me - nginx.git/commitdiff
allow "http://" in auth_http URL
authorIgor Sysoev <igor@sysoev.ru>
Tue, 14 Aug 2007 15:00:38 +0000 (15:00 +0000)
committerIgor Sysoev <igor@sysoev.ru>
Tue, 14 Aug 2007 15:00:38 +0000 (15:00 +0000)
src/mail/ngx_mail_auth_http_module.c

index 2cb084112e9d8b70f07f0f611cacbc3464bdb283..c7484c469191096d59372590e417bb5e794ecce0 100644 (file)
@@ -1383,6 +1383,11 @@ ngx_mail_auth_http(ngx_conf_t *cf, ngx_command_t *cmd, void *conf)
     u.uri_part = 1;
     u.one_addr = 1;
 
+    if (ngx_strncmp(u.url.data, "http://", 7) == 0) {
+        u.url.len -= 7;
+        u.url.data += 7;
+    }
+
     if (ngx_parse_url(cf, &u) != NGX_OK) {
         if (u.err) {
             ngx_conf_log_error(NGX_LOG_EMERG, cf, 0,