comparison src/mail/ngx_mail.c @ 2049:2a92804f4109

*) back out r2040 *) refactor ngx_palloc() *) introduce ngx_pnalloc() *) additional pool blocks have smaller header
author Igor Sysoev <igor@sysoev.ru>
date Tue, 17 Jun 2008 15:00:30 +0000
parents cb8c0c8e0c27
children 74477ea8074f
comparison
equal deleted inserted replaced
2048:824615f3b4ec 2049:2a92804f4109
355 355
356 for (i = 0; i < imip->naddrs; i++) { 356 for (i = 0; i < imip->naddrs; i++) {
357 imip->addrs[i].addr = in_addr[i].addr; 357 imip->addrs[i].addr = in_addr[i].addr;
358 imip->addrs[i].ctx = in_addr[i].ctx; 358 imip->addrs[i].ctx = in_addr[i].ctx;
359 359
360 text = ngx_palloc(cf->pool, 360 text = ngx_pnalloc(cf->pool,
361 INET_ADDRSTRLEN - 1 + sizeof(":65535") - 1); 361 INET_ADDRSTRLEN - 1 + sizeof(":65535") - 1);
362 if (text == NULL) { 362 if (text == NULL) {
363 return NGX_CONF_ERROR; 363 return NGX_CONF_ERROR;
364 } 364 }
365 365
366 len = ngx_inet_ntop(AF_INET, &in_addr[i].addr, text, 366 len = ngx_inet_ntop(AF_INET, &in_addr[i].addr, text,