Fixed a bug with the DMS counter being wrongly initialized to 0 instead
of 1 (generating memory bugs when using the counter)
This commit is contained in:
12
src/obidms.c
12
src/obidms.c
@ -588,7 +588,7 @@ static int list_dms(OBIDMS_p dms)
|
|||||||
if (global_opened_dms_list[i] == NULL)
|
if (global_opened_dms_list[i] == NULL)
|
||||||
{ // new dms
|
{ // new dms
|
||||||
global_opened_dms_list[i] = dms;
|
global_opened_dms_list[i] = dms;
|
||||||
global_opened_dms_counter_list[i] = 0;
|
global_opened_dms_counter_list[i] = 1;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{ // already opened dms
|
{ // already opened dms
|
||||||
@ -1543,7 +1543,7 @@ int obi_import_view(const char* dms_path_1, const char* dms_path_2, const char*
|
|||||||
|
|
||||||
// Create new view
|
// Create new view
|
||||||
if (strcmp((view_1->infos)->view_type, VIEW_TYPE_NUC_SEQS) == 0)
|
if (strcmp((view_1->infos)->view_type, VIEW_TYPE_NUC_SEQS) == 0)
|
||||||
view_2 = obi_new_view_nuc_seqs(dms_2, view_name_2, NULL, NULL, (view_1->infos)->comments, false);
|
view_2 = obi_new_view_nuc_seqs(dms_2, view_name_2, NULL, NULL, (view_1->infos)->comments, false, false);
|
||||||
else // Non-typed view
|
else // Non-typed view
|
||||||
view_2 = obi_new_view(dms_2, view_name_2, NULL, NULL, (view_1->infos)->comments);
|
view_2 = obi_new_view(dms_2, view_name_2, NULL, NULL, (view_1->infos)->comments);
|
||||||
|
|
||||||
@ -1596,10 +1596,10 @@ int obi_import_view(const char* dms_path_1, const char* dms_path_2, const char*
|
|||||||
-1,
|
-1,
|
||||||
NULL,
|
NULL,
|
||||||
false) < 0)
|
false) < 0)
|
||||||
{
|
{
|
||||||
obidebug(1, "\nError adding a column to a view while importing it");
|
obidebug(1, "\nError adding a column to a view while importing it");
|
||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// Close the views
|
// Close the views
|
||||||
|
Reference in New Issue
Block a user