summaryrefslogtreecommitdiff
blob: d1e80184e5b12a1a30256a1a2e0cccf1b28c2526 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
Index: libiodbc2-3.52.7/iodbcinst/inifile.c
===================================================================
--- libiodbc2-3.52.7.orig/iodbcinst/inifile.c	2010-06-26 21:29:43.000000000 +0200
+++ libiodbc2-3.52.7/iodbcinst/inifile.c	2010-06-26 21:30:07.000000000 +0200
@@ -1023,7 +1023,8 @@
 
   if (!_iodbcdm_cfg_find (pCfg, lpszSection, NULL))
     {
-      while (curr < cbRetBuffer && 0 == _iodbcdm_cfg_nextentry (pCfg))
+      while (curr < cbRetBuffer && 0 == _iodbcdm_cfg_nextentry (pCfg)
+	     && pCfg->section)
 	{
 	  if (_iodbcdm_cfg_section (pCfg))
 	    break;