Skip to content

Commit

Permalink
change back release_weight_vectors to SG_FREE
Browse files Browse the repository at this point in the history
  • Loading branch information
vigsterkr committed Feb 14, 2014
1 parent 19ff58e commit 40d583a
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions src/shogun/classifier/vw/VwRegressor.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ CVwRegressor::~CVwRegressor()
{
// TODO: the number of weight_vectors depends on num_threads
// this should be reimplemented using SGVector (for reference counting)
release_weight_vectors();
SG_FREE(weight_vectors);
SG_UNREF(loss);
SG_UNREF(env);
}
Expand Down Expand Up @@ -224,7 +224,7 @@ void CVwRegressor::load_regressor(char* file)

// Initialize the weight vector
if (weight_vectors)
release_weight_vectors();
SG_FREE(weight_vectors);
init(env);

vw_size_t local_ngram;
Expand Down Expand Up @@ -256,4 +256,3 @@ void CVwRegressor::load_regressor(char* file)
}
source.close_file();
}

0 comments on commit 40d583a

Please sign in to comment.