Index: www/hacking.html =================================================================== --- www/hacking.html (revision 18625) +++ www/hacking.html (working copy) @@ -619,7 +619,7 @@ to quote them. (e.g. "Can't find '/path/to/repos/userfile'").
When including path or filenames in the error string, be sure - to convert them using 'svn_path_local_style ()' before inclusion.
If you want to add an explanation to the error, report it followed by a colon and the explanation like this:
@@ -672,8 +672,8 @@ then use two underscores following the module prefix. For example:
- svn_fs_get_rev_prop () /* Part of published API. */
- svn_fs__parse_props () /* For internal use only. */
+ svn_fs_get_rev_prop() /* Part of published API. */
+ svn_fs__parse_props() /* For internal use only. */
- apr_pool_t *subpool = svn_pool_create (pool);
+ apr_pool_t *subpool = svn_pool_create(pool);
for (i = 0; i < n; ++i)
{
- svn_pool_clear (subpool);
- do_operation (..., subpool);
+ svn_pool_clear(subpool);
+ do_operation(..., subpool);
}
- svn_pool_destroy (subpool);
+ svn_pool_destroy(subpool);
@@ -809,20 +809,20 @@
code:
- apr_hash_t *persistent_objects = apr_hash_make (pool);
- apr_pool_t *subpool = svn_pool_create (pool);
+ apr_hash_t *persistent_objects = apr_hash_make(pool);
+ apr_pool_t *subpool = svn_pool_create(pool);
for (i = 0; i < n; ++i)
{
const char *intermediate_result;
const char *key, *val;
- svn_pool_clear (subpool);
- SVN_ERR (do_something (&intermediate_result, ..., subpool));
- SVN_ERR (get_result (intermediate_result, &key, &val, ..., pool));
- apr_hash_set (persistent_objects, key, APR_HASH_KEY_STRING, val);
+ svn_pool_clear(subpool);
+ SVN_ERR(do_something(&intermediate_result, ..., subpool));
+ SVN_ERR(get_result(intermediate_result, &key, &val, ..., pool));
+ apr_hash_set(persistent_objects, key, APR_HASH_KEY_STRING, val);
}
- svn_pool_destroy (subpool);
+ svn_pool_destroy(subpool);
return persistent_objects;
@@ -843,8 +843,8 @@
static foo_t *
make_foo_object (arg1, arg2, apr_pool_t *pool)
{
- apr_pool_t *subpool = svn_pool_create (pool);
- foo_t *foo = apr_palloc (subpool, sizeof (*foo));
+ apr_pool_t *subpool = svn_pool_create(pool);
+ foo_t *foo = apr_palloc(subpool, sizeof(*foo));
foo->field1 = arg1;
foo->field2 = arg2;
@@ -957,8 +957,8 @@
something like this:
-return svn_error_create (SVN_ERR_FOO, NULL,
- "User not permitted to write file");
+return svn_error_create(SVN_ERR_FOO, NULL,
+ "User not permitted to write file");
NOTICE the NULL field... indicating that this error has no @@ -990,7 +990,7 @@
Throw the error upwards, unmodified:
- error = some_routine (foo);
+ error = some_routine(foo);
if (error)
return (error);
@@ -998,7 +998,7 @@
Actually, a better way to do this would be with the SVN_ERR() macro, which does the same thing:
- SVN_ERR (some_routine (foo));
+ SVN_ERR(some_routine(foo));
- error = some_routine (foo);
+ error = some_routine(foo);
if (error)
{
- svn_error_t *wrapper = svn_error_create (SVN_ERR_FOO, error,
- "Authorization failed");
+ svn_error_t *wrapper = svn_error_create(SVN_ERR_FOO, error,
+ "Authorization failed");
return wrapper;
}
@@ -1020,11 +1020,11 @@
your custom message:
- error = some_routine (foo);
+ error = some_routine(foo);
if (error)
{
- return svn_error_quick_wrap (error,
- "Authorization failed");
+ return svn_error_quick_wrap(error,
+ "Authorization failed");
}
@@ -1032,7 +1032,7 @@
macro:
- SVN_ERR_W (some_routine (foo), "Authorization failed");
+ SVN_ERR_W(some_routine(foo), "Authorization failed");
@@ -1453,7 +1453,7 @@
And then, in `consume_count' in `cplus-dem.c':
- while (isdigit ((unsigned char)**type))
+ while (isdigit((unsigned char)**type))
{
count *= 10;
count += **type - '0';
@@ -1461,7 +1461,7 @@
`_Utf390_1__1_9223372036854775807__9223372036854775'
can cause this function to return a negative value.
In this case we just consume until the end of the string. */
- if (count > strlen (*type))
+ if (count > strlen(*type))
{
*type = save;
return 0;
@@ -2311,15 +2311,15 @@
* Similar to svn_repos_dump_fs2(), but with the @a use_deltas
* parameter always set to @c FALSE.
*/
- svn_error_t *svn_repos_dump_fs (svn_repos_t *repos,
- svn_stream_t *dumpstream,
- svn_stream_t *feedback_stream,
- svn_revnum_t start_rev,
- svn_revnum_t end_rev,
- svn_boolean_t incremental,
- svn_cancel_func_t cancel_func,
- void *cancel_baton,
- apr_pool_t *pool);
+ svn_error_t *svn_repos_dump_fs(svn_repos_t *repos,
+ svn_stream_t *dumpstream,
+ svn_stream_t *feedback_stream,
+ svn_revnum_t start_rev,
+ svn_revnum_t end_rev,
+ svn_boolean_t incremental,
+ svn_cancel_func_t cancel_func,
+ void *cancel_baton,
+ apr_pool_t *pool);
When the major release number changes, the "best" new API in a