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

Re: pre-revprop-change hook problems

From: Philip Martin <philip_at_codematters.co.uk>
Date: 2005-09-28 18:41:16 CEST

"C. Michael Pilato" <cmpilato@collab.net> writes:

> NULL authors get passed to all our hooks as the empty string. Is this
> something that the hook's language or that APR's process code on that
> platform doesn't support?

Looks like an APR bug in win32/proc.c:apr_proc_create:

    cmdline = "";
    for (i = 1; args && args[i]; ++i) {
        if (has_space(args[i])) {
            cmdline = apr_pstrcat(pool, cmdline, " \"", args[i], "\"", NULL);
        }
        else {
            cmdline = apr_pstrcat(pool, cmdline, " ", args[i], NULL);
        }
    }

Subversion passes an empty string, a single '\0' character, has_space
will return NULL, and so apr_pstrcat will just add a space without
quotes.

-- 
Philip Martin
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Wed Sep 28 18:47:04 2005

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.