From 5a2333573cdbf1f0a3fa99690b861b5f9e9a09d1 Mon Sep 17 00:00:00 2001 From: Howard Chu Date: Tue, 1 Mar 2005 21:16:44 +0000 Subject: [PATCH] Fix prev commit --- servers/slapd/slapi/plugin.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/servers/slapd/slapi/plugin.c b/servers/slapd/slapi/plugin.c index b2ff3d82c5..6ebe041408 100644 --- a/servers/slapd/slapi/plugin.c +++ b/servers/slapd/slapi/plugin.c @@ -24,6 +24,7 @@ #include #include #include +#include /* * Note: if ltdl.h is not available, slapi should not be compiled @@ -778,13 +779,13 @@ slapi_int_plugin_unparse( slapi_pblock_get( pp, SLAPI_X_CONFIG_ARGV, &argv ); idx.bv_len = sprintf( idx.bv_val, "{%d}", i ); bv.bv_len = idx.bv_len; - for (j=0; argv[j]; j++) { + for (j=1; argv[j]; j++) { bv.bv_len += strlen(argv[j]); if ( j ) bv.bv_len++; } bv.bv_val = ch_malloc( bv.bv_len + 1 ); ptr = lutil_strcopy( bv.bv_val, ibuf ); - for (j=0; argv[j]; j++) { + for (j=1; argv[j]; j++) { if ( j ) *ptr++ = ' '; ptr = lutil_strcopy( ptr, argv[j] ); } -- 2.39.5