[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

A possible RA plugin ABI problem

From: Tobias Ringstrom <tobias_at_ringstrom.mine.nu>
Date: 2004-01-13 16:35:39 CET

The RA plugin init function takes an ABI version as it's first parameter
to be able to verify that the caller's ABI version matches the plugin.
The problem is that it is defined to return an svn_error_t pointer when
the ABI does not match.

If the new ABI would change the type of svn_error_t, the caller would
most likely crash if it tried to show the error to the user.

This can be fixed by changing the init function prototype to

  * The return value is zero if the @a abi_version is supported, else
  * @c -1. The output argument @a err is only valid if the function
  * returns zero.
typedef int (*svn_ra_init_func_t) (int abi_version,
                                    svn_error_t **err,
                                    apr_pool_t *pool,
                                    apr_hash_t *hash);

Do you agree that this needs to be fixed, and that this fix is good?


To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Tue Jan 13 16:36:11 2004

This is an archived mail posted to the Subversion Dev mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.