On 10/24/13 11:44 AM, Maximo, Andre (GE Global Research) wrote: > void CVCS::svnURLPath(CString& urlPath, const CString &fullPath) > > { > > apr_pool_t *local_pool = svn_pool_create(m_svn_pool); > > const char *url = NULL; > > svn_error_t *err = svn_client_url_from_path2(&url, fullPath, m_svn_ctx, > m_svn_pool, local_pool); > > if (url != NULL) > > urlPath = CString(url); > > svn_pool_destroy(local_pool); > > } > > > > Where “m_svn_ctx” and “m_svn_pool” are pointers to class member context and > main pool. What happens is that when I call this method for a valid fullPath > it returns a valid urlPath. But, if I passed a non-existent fullPath, the code > crashes at the “svn_client_url_from_path2”.
I'm not seeing a problem with our code based on the condition you've identified. We have almost identical code in the svn_cl__revprop_prepare() which is in subversion/svn/props.c to what you're doing. The only differences that I see are we aren't using a separate scratch and result pool and we actually check the error response from svn_client_url_from_path2(). The incoming URL pointer we use is NULL just like yours. I can excercise the above mentioned code path by doing the following: svn propget -r 1535399 --revprop svn:date FAKEPATH (where FAKEPATH doesn't exist) I don't get crashes with 1.7, 1.8 or trunk. Out of curiosity I went and added a scratch pool to the code and still didn't get any crashes. Perhaps there is some other condition required to replicate your issue?