Test Build:CUBRID 2008 R4.0 (8.4.0.2019) (64bit release build for linux_gnu)
OS: Linux 64
Description: Error will appear when calling cubrid_lob_import method 1019 times
Repro Steps:
perl memoryleak_2.pl
Statements in memoryleak_2.pl
{noformat}
my $x=1;
while($x10000000){
print $x\n;
$x++;
$dbh=DBI-connect($dsn, $user, $pass,{RaiseError = 1}) or die connect error: $dbh-errstr;
print ##################start cubrid_lob_import_05.pl######################################\n;
$dbh - do(drop table if EXISTS import_2;) or die drop error: $dbh-errstr;
$dbh-do(CREATE TABLE import_2 (image_id VARCHAR(36) PRIMARY KEY, image BLOB);) or die create error: $dbh-errstr;
my $sth=$dbh-prepare(insert into import_2 values(?,?);) or die prepare error: $dbh-errstr;
$sth-bind_param (1, 1) or die bind_param error: $dbh-errstr;
my $ip=$sth-cubrid_lob_import (2, import2.txt, DBI::SQL_BLOB) or die $dbh-errstr . cubrid_lob_import error:\n;
$sth-execute() or die $dbh-errstr .execute error: $dbh-errstr;
$sth-cubrid_lob_close();
$dbh - do(drop table if EXISTS import_2;) or die drop error: $dbh-errstr;
$sth-finish();
$dbh - disconnect();
print \n\n\n;
}
{noformat}
Actual result:
I executed this program many times. and every times when executing 1019 times error appear.
{noformat}
1019
##################start cubrid_lob_import_04.pl######################################
Error : Cannot open file :cubrid_lob_import error
{noformat}
Expect result:
{noformat}
no error
{noformat}