Navigation Menu

Skip to content

Commit

Permalink
fix memory leak.
Browse files Browse the repository at this point in the history
  • Loading branch information
ikdttr committed May 11, 2009
1 parent 17eb686 commit 4ce1fb2
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/ha_groonga.cc
Expand Up @@ -195,7 +195,8 @@ int ha_groonga::create(const char *name, TABLE *form, HA_CREATE_INFO *info)

MRN_LOG(GRN_LOG_DEBUG, "-> grn_obj_close: table_obj=%p", table_obj);
grn_obj_close(mrn_ctx_tls, table_obj);

grn_obj_close(mrn_ctx_tls, key_type);
grn_obj_close(mrn_ctx_tls, type);
return 0;

err:
Expand Down Expand Up @@ -348,6 +349,7 @@ int ha_groonga::rnd_next(uchar *buf)
(*mysql_field)->store(*val);
}
this->record_id = gid;
grn_obj_close(mrn_ctx_tls, &obj);
return 0;
} else {
MRN_LOG(GRN_LOG_DEBUG, "-> grn_table_cursor_close: this->cursor=%p", this->cursor);
Expand Down

0 comments on commit 4ce1fb2

Please sign in to comment.