2
0
Эх сурвалжийг харах

db_text: close file stream in case of error reading table file

Daniel-Constantin Mierla 8 жил өмнө
parent
commit
cdf2976b85

+ 2 - 0
src/modules/db_text/dbt_file.c

@@ -489,6 +489,8 @@ clean:
 	LM_DBG("error at row=%d col=%d c=%c\n", crow+1, ccol+1, c);
 	LM_DBG("error at row=%d col=%d c=%c\n", crow+1, ccol+1, c);
 	if(dtp)
 	if(dtp)
 		dbt_table_free(dtp);
 		dbt_table_free(dtp);
+	if(fin)
+		fclose(fin);
 	if(buf)
 	if(buf)
 		pkg_free(buf);
 		pkg_free(buf);
 	return NULL;
 	return NULL;