diff src/mail/ngx_mail_handler.c @ 296:2ceaee987f37 NGINX_0_5_18

nginx 0.5.18 *) Feature: the ngx_http_sub_filter_module. *) Feature: the "$upstream_http_..." variables. *) Feature: now the $upstream_status and $upstream_response_time variables keep data about all upstreams before X-Accel-Redirect. *) Bugfix: a segmentation fault occurred in master process after first reconfiguration and receiving any signal if nginx was built with ngx_http_perl_module and perl did not support multiplicity; bug appeared in 0.5.9. *) Bugfix: if perl did not support multiplicity, then after reconfiguration perl code did not work; bug appeared in 0.3.38.
author Igor Sysoev <http://sysoev.ru>
date Thu, 19 Apr 2007 00:00:00 +0400
parents f745bf973510
children fc223117327f
line wrap: on
line diff
--- a/src/mail/ngx_mail_handler.c
+++ b/src/mail/ngx_mail_handler.c
@@ -297,19 +297,19 @@ ngx_mail_init_session(ngx_connection_t *
                      - s->salt.data;
 
         if (s->protocol == NGX_MAIL_POP3_PROTOCOL) {
-	    s->out.data = ngx_palloc(c->pool,
+            s->out.data = ngx_palloc(c->pool,
                                      greetings[0].len + 1 + s->salt.len);
-	    if (s->out.data == NULL) {
-		ngx_mail_session_internal_server_error(s);
-		return;
-	    }
+            if (s->out.data == NULL) {
+                ngx_mail_session_internal_server_error(s);
+                return;
+            }
 
-	    p = ngx_cpymem(s->out.data,
+            p = ngx_cpymem(s->out.data,
                            greetings[0].data, greetings[0].len - 2);
-	    *p++ = ' ';
-	    p = ngx_cpymem(p, s->salt.data, s->salt.len);
+            *p++ = ' ';
+            p = ngx_cpymem(p, s->salt.data, s->salt.len);
 
-	    s->out.len = p - s->out.data;
+            s->out.len = p - s->out.data;
         }
     }
 
@@ -1408,31 +1408,31 @@ ngx_smtp_auth_state(ngx_event_t *rev)
             case NGX_SMTP_MAIL:
 
                 if (s->connection->log->log_level >= NGX_LOG_INFO) {
-		    l.len = s->buffer->last - s->buffer->start;
-		    l.data = s->buffer->start;
+                    l.len = s->buffer->last - s->buffer->start;
+                    l.data = s->buffer->start;
 
-		    for (i = 0; i < l.len; i++) {
-			ch = l.data[i];
+                    for (i = 0; i < l.len; i++) {
+                        ch = l.data[i];
 
-			if (ch != CR && ch != LF) {
-			    continue;
-			}
+                        if (ch != CR && ch != LF) {
+                            continue;
+                        }
 
-			l.data[i] = ' ';
-		    }
+                        l.data[i] = ' ';
+                    }
 
-		    while (i) {
-			if (l.data[i - 1] != ' ') {
-			    break;
-			}
+                    while (i) {
+                        if (l.data[i - 1] != ' ') {
+                            break;
+                        }
 
-			i--;
-		    }
+                        i--;
+                    }
 
-		    l.len = i;
+                    l.len = i;
 
-		    ngx_log_error(NGX_LOG_INFO, s->connection->log, 0,
-				  "client was rejected: \"%V\"", &l);
+                    ngx_log_error(NGX_LOG_INFO, s->connection->log, 0,
+                                  "client was rejected: \"%V\"", &l);
                 }
 
                 text = smtp_auth_required;