mirror of
https://git.openldap.org/openldap/openldap.git
synced 2025-12-24 00:29:35 -05:00
Only non-postoperation plugins should be able to abort processing of further
plugins.
This commit is contained in:
parent
b53eef9b81
commit
27dba2226f
2 changed files with 7 additions and 3 deletions
|
|
@ -571,8 +571,6 @@ doPluginFNs(
|
|||
|
||||
for ( pGetPlugin = tmpPlugin ; *pGetPlugin != NULL; pGetPlugin++ ) {
|
||||
/*
|
||||
* FIXME: operation stops at first non-success
|
||||
*
|
||||
* FIXME: we should provide here a sort of sandbox,
|
||||
* to protect from plugin faults; e.g. trap signals
|
||||
* and longjump here, marking the plugin as unsafe for
|
||||
|
|
@ -580,7 +578,11 @@ doPluginFNs(
|
|||
*/
|
||||
rc = (*pGetPlugin)(pPB);
|
||||
|
||||
if ( rc != LDAP_SUCCESS ) {
|
||||
/*
|
||||
* Only non-postoperation plugins abort processing on
|
||||
* failure (confirmed with SLAPI specification).
|
||||
*/
|
||||
if ( !SLAPI_PLUGIN_IS_POST_FN( funcType ) && rc != 0 ) {
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -24,5 +24,7 @@ int netscape_plugin(Backend *be, const char *fname, int lineno,
|
|||
int argc, char **argv );
|
||||
int slapi_init(void);
|
||||
|
||||
#define SLAPI_PLUGIN_IS_POST_FN(x) ((x) >= SLAPI_PLUGIN_POST_BIND_FN && (x) <= SLAPI_PLUGIN_POST_RESULT_FN)
|
||||
|
||||
#endif /* _PLUGIN_H_ */
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue