On Tue, Nov 06, 2001 at 10:01:28AM -0600, Karl Fogel wrote:
> While reviewing Philip Martin's recent patch to svn_client_propget(),
> I got a closer look at some of our recent property changes. The doc
> string for svn_client_propget() left me a little lost as to the
> precise form of the return-by-reference.
> Eventually I was able to determine that it's using
> `apr_table_entry_t'. But that's bad: it forces the property value to
> be a `char *', meaning no prop values with nulls in them. We decided
> long ago that property *names* didn't have to support binary strings,
> but property values are Anything Goes.
I wasn't aware of that, and indeed was comtemplating using either a table
or a hash.
> Kevin Pilch-Bisson, I think this was your commit 290? Can you fix it
> please? Suggest returning them in a hash, where the keys are `char *'
> propnames and the values are `svn_string_t *'.
No problem, especially since it seems my network is working again.
> /* Returns an apr_table_t of filenames and property values, in *PROPS,
> allocated in POOL. If TARGET is a file or RECURSE is false, there will
> be only a single element, with key TARGET, and value the value of PROPNAME
> in TARGET. If recurse is true and TARGET is a directory, the *PROPS will
> contain a list of node names and property values for TARGET and all of
> its children. The nodenames will be of rooted from the same place as
> TARGET. */
Thinking of a doc-string along the following lines:
/* Returns an apr_hash_t where the key is a char * representing the path
from the pwd to the node on which property PROPNAME is set, and the key
is the value of PROPNAME on that node. If TARGET is a file or RECURSE is
false, there will be only a single element in *PROPS, with key TARGET->data.
I thought of having a hash of hashes (or table of hashes), similar to proplist,
but thought this would be redundant, since we are only getting a single
> svn_error_t *
> svn_client_propget (apr_table_t **props,
> svn_stringbuf_t *propname,
> svn_stringbuf_t *target,
> svn_boolean_t recurse,
> apr_pool_t *pool);
Kevin Pilch-Bisson http://www.pilch-bisson.net
"Historically speaking, the presences of wheels in Unix
has never precluded their reinvention." - Larry Wall
Received on Sat Oct 21 14:36:48 2006
- application/pgp-signature attachment: stored