FreeBSD/contrib/subversion/subversion/libsvn_ra_serf/property.c
/* For HTTPv1 servers, do a PROPFIND dance on the VCC to fetch the youngest
   revnum. If BASECOLL_URL is non-NULL, then the corresponding baseline
   collection URL is also returned.

   Do the work over CONN.

   *BASECOLL_URL (if requested) will be allocated in RESULT_POOL. All
   temporary allocations will be made in SCRATCH_POOL.  */
For HTTPv1 servers, do a PROPFIND dance on the VCC to fetch the youngest
revnum. If BASECOLL_URL is non-NULL, then the corresponding baseline
collection URL is also returned.

Do the work over CONN.

BASECOLL_URL (if requested) will be allocated in RESULT_POOL. All
temporary allocations will be made in SCRATCH_POOL.
For HTTPv1 servers do a PROPFIND dance on the VCC to fetch the youngest revnum . If BASECOLL_URL is non - NULL then the corresponding baseline collection URL is also returned . Do the work over CONN . BASECOLL_URL ( if requested ) will be allocated in RESULT_POOL . All temporary allocations will be made in SCRATCH_POOL .
static svn_error_t *
v1_get_youngest_revnum(svn_revnum_t *youngest,
                       const char **basecoll_url,
                       svn_ra_serf__session_t *session,
                       const char *vcc_url,
                       apr_pool_t *result_pool,
                       apr_pool_t *scratch_pool)
{
  const char *baseline_url;
  const char *bc_url;
  SVN_ERR(svn_ra_serf__fetch_dav_prop(&baseline_url, session, vcc_url,
                                      SVN_INVALID_REVNUM,
                                      "checked-in",
                                      scratch_pool, scratch_pool));
  if (!baseline_url)
    {
      return svn_error_create(SVN_ERR_RA_DAV_OPTIONS_REQ_FAILED, NULL,
                              _("The OPTIONS response did not include "
                                "the requested checked-in value"));
    }
  baseline_url = svn_urlpath__canonicalize(baseline_url, scratch_pool);
  SVN_ERR(svn_ra_serf__blncache_get_baseline_info(&bc_url,
                                                  youngest,
                                                  session->blncache,
                                                  baseline_url,
                                                  scratch_pool));
  if (!bc_url)
    {
      SVN_ERR(retrieve_baseline_info(youngest, &bc_url, session,
                                     baseline_url, SVN_INVALID_REVNUM,
                                     scratch_pool, scratch_pool));
      SVN_ERR(svn_ra_serf__blncache_set(session->blncache,
                                        baseline_url, *youngest,
                                        bc_url, scratch_pool));
    }
  if (basecoll_url != NULL)
    *basecoll_url = apr_pstrdup(result_pool, bc_url);
  return SVN_NO_ERROR;
}
static svn_error_t * v1_get_youngest_revnum ( svn_revnum_t * youngest , const char * * basecoll_url , svn_ra_serf__session_t * session , const char * vcc_url , apr_pool_t * result_pool , apr_pool_t * scratch_pool ) { const char * baseline_url ; const char * bc_url ; SVN_ERR ( svn_ra_serf__fetch_dav_prop ( & baseline_url , session , vcc_url , SVN_INVALID_REVNUM , " " , scratch_pool , scratch_pool ) ) ; if ( ! baseline_url ) { return svn_error_create ( SVN_ERR_RA_DAV_OPTIONS_REQ_FAILED , NULL , _ ( " " " " ) ) ; } baseline_url = svn_urlpath__canonicalize ( baseline_url , scratch_pool ) ; SVN_ERR ( svn_ra_serf__blncache_get_baseline_info ( & bc_url , youngest , session -> blncache , baseline_url , scratch_pool ) ) ; if ( ! bc_url ) { SVN_ERR ( retrieve_baseline_info ( youngest , & bc_url , session , baseline_url , SVN_INVALID_REVNUM , scratch_pool , scratch_pool ) ) ; SVN_ERR ( svn_ra_serf__blncache_set ( session -> blncache , baseline_url , * youngest , bc_url , scratch_pool ) ) ; } if ( basecoll_url != NULL ) * basecoll_url = apr_pstrdup ( result_pool , bc_url ) ; return SVN_NO_ERROR ; }
For HTTPv1 servers, do a PROPFIND dance on the VCC to fetch the youngest
revnum.
For HTTPv1 servers do a PROPFIND dance on the VCC to fetch the youngest revnum .
/* Fetching DAV:checked-in from the VCC (with no Label: to specify a
     revision) will return the latest Baseline resource's URL.  */ /* From the Baseline resource, we can fetch the DAV:baseline-collection
     and DAV:version-name properties. The latter is the revision number,
     which is formally the name used in Label: headers.  */ /* First check baseline information cache. */