瀏覽代碼

Bug 630091 - (cov#15519) Initialize bervals in search_easter_egg()

In search_easter_egg(), we need to initialize the bervals before
we pass them to slapi_ldif_parse_line().
Nathan Kinder 15 年之前
父節點
當前提交
88ee6cf054
共有 1 個文件被更改,包括 2 次插入2 次删除
  1. 2 2
      ldap/servers/slapd/fedse.c

+ 2 - 2
ldap/servers/slapd/fedse.c

@@ -1728,8 +1728,8 @@ search_easter_egg( Slapi_PBlock *pb, Slapi_Entry *entryBefore, Slapi_Entry *entr
     {
     {
 		static int twiddle= -1;
 		static int twiddle= -1;
 		char *copy;
 		char *copy;
-		struct berval bvtype;
-		struct berval bv;
+		struct berval bvtype = {0, NULL};
+		struct berval bv = {0, NULL};
 		int freeval = 0;
 		int freeval = 0;
 		struct berval *bvals[2];
 		struct berval *bvals[2];
 		if (twiddle < 0) {
 		if (twiddle < 0) {