From 144c3fe342504b92e34b75a975349ce567f03978 Mon Sep 17 00:00:00 2001 From: Jeff Trawick Date: Thu, 16 Mar 2006 19:39:38 +0000 Subject: [PATCH] Clean up some string manipulation. Submitted by: Christophe JAILLET Reviewed by: Jeff Trawick PR: 38701 git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@386437 13f79535-47bb-0310-9956-ffa450edef68 --- modules/aaa/mod_authnz_ldap.c | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/modules/aaa/mod_authnz_ldap.c b/modules/aaa/mod_authnz_ldap.c index ca21a618e9..29635ef7eb 100644 --- a/modules/aaa/mod_authnz_ldap.c +++ b/modules/aaa/mod_authnz_ldap.c @@ -1117,11 +1117,7 @@ static const char *mod_auth_ldap_parse_url(cmd_parms *cmd, /* Set all the values, or at least some sane defaults */ if (sec->host) { - char *p = apr_palloc(cmd->pool, strlen(sec->host) + strlen(urld->lud_host) + 2); - strcpy(p, urld->lud_host); - strcat(p, " "); - strcat(p, sec->host); - sec->host = p; + sec->host = apr_pstrcat(cmd->pool, urld->lud_host, " ", sec->host, NULL); } else { sec->host = urld->lud_host? apr_pstrdup(cmd->pool, urld->lud_host) : "localhost"; -- 2.40.0