[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Help-glpk] Determining if glp_error_hook is set
From: |
glpk xypron |
Subject: |
Re: [Help-glpk] Determining if glp_error_hook is set |
Date: |
Mon, 08 Mar 2010 07:35:52 +0100 |
Hello Andrew,
>
> > Is there a way to determine if the error hook function is
> > already set or not?
>
> Currently not, however, glp_error_hook can be changed to return, say,
> the following structure:
>
> typedef struct { void *func, *info; } glp_hook;
that is just the kind of solution I was thinking of.
So
glp_hook ret = glp_error_hook(my_cb, my_info);
would return the prior values of func and info.
If glp_error_hook is called the first time
ret.func = NULL;
ret.info = NULL;
It should be save to simply call
glp_error_hook(my_cb, my_info);
if the return information is not needed.
Best regards
Xypron
--
GRATIS für alle GMX-Mitglieder: Die maxdome Movie-FLAT!
Jetzt freischalten unter http://portal.gmx.net/de/go/maxdome01