From: stevenj Date: Wed, 8 Aug 2012 15:52:19 +0000 (-0400) Subject: bug fix: fix return value in set min/max objective X-Git-Url: https://www.chiark.greenend.org.uk/ucgi/~ianmdlvl/git?a=commitdiff_plain;h=aeb1ae8294288dd969b3b6f2a208da82ada23385;p=nlopt.git bug fix: fix return value in set min/max objective Ignore-this: f52cbe2ff3c98d53de6f08185493b85b darcs-hash:20120808155219-c8de0-38a56084114dcc06040700a283f5f21a684a38e1.gz --- diff --git a/api/options.c b/api/options.c index 4a4936e..8b75c15 100644 --- a/api/options.c +++ b/api/options.c @@ -231,7 +231,7 @@ nlopt_result NLOPT_STDCALL nlopt_set_precond_min_objective(nlopt_opt opt, nlopt_result NLOPT_STDCALL nlopt_set_min_objective(nlopt_opt opt, nlopt_func f, void *f_data) { - nlopt_set_precond_min_objective(opt, f, NULL, f_data); + return nlopt_set_precond_min_objective(opt, f, NULL, f_data); } nlopt_result NLOPT_STDCALL nlopt_set_precond_max_objective(nlopt_opt opt, @@ -253,7 +253,7 @@ nlopt_result NLOPT_STDCALL nlopt_set_precond_max_objective(nlopt_opt opt, nlopt_result NLOPT_STDCALL nlopt_set_max_objective(nlopt_opt opt, nlopt_func f, void *f_data) { - nlopt_set_precond_max_objective(opt, f, NULL, f_data); + return nlopt_set_precond_max_objective(opt, f, NULL, f_data); } /*************************************************************************/