aboutsummaryrefslogtreecommitdiffstats
path: root/subversion/libsvn_ra_svn
diff options
context:
space:
mode:
Diffstat (limited to 'subversion/libsvn_ra_svn')
-rw-r--r--subversion/libsvn_ra_svn/client.c22
-rw-r--r--subversion/libsvn_ra_svn/editorp.c2
-rw-r--r--subversion/libsvn_ra_svn/libsvn_ra_svn.pc.in8
-rw-r--r--subversion/libsvn_ra_svn/protocol2
4 files changed, 25 insertions, 9 deletions
diff --git a/subversion/libsvn_ra_svn/client.c b/subversion/libsvn_ra_svn/client.c
index ab1aa58cdc48..f48451900aaf 100644
--- a/subversion/libsvn_ra_svn/client.c
+++ b/subversion/libsvn_ra_svn/client.c
@@ -841,6 +841,7 @@ is_valid_hostinfo(const char *hostinfo)
static svn_error_t *ra_svn_open(svn_ra_session_t *session,
const char **corrected_url,
+ const char **redirect_url,
const char *url,
const svn_ra_callbacks2_t *callbacks,
void *callback_baton,
@@ -858,6 +859,8 @@ static svn_error_t *ra_svn_open(svn_ra_session_t *session,
/* We don't support server-prescribed redirections in ra-svn. */
if (corrected_url)
*corrected_url = NULL;
+ if (redirect_url)
+ *redirect_url = NULL;
SVN_ERR(parse_url(url, &uri, sess_pool));
@@ -913,7 +916,7 @@ static svn_error_t *ra_svn_dup_session(svn_ra_session_t *new_session,
{
svn_ra_svn__session_baton_t *old_sess = old_session->priv;
- SVN_ERR(ra_svn_open(new_session, NULL, new_session_url,
+ SVN_ERR(ra_svn_open(new_session, NULL, NULL, new_session_url,
old_sess->callbacks, old_sess->callbacks_baton,
old_sess->auth_baton, old_sess->config,
result_pool, scratch_pool));
@@ -3105,6 +3108,7 @@ ra_svn_get_deleted_rev(svn_ra_session_t *session,
{
svn_ra_svn__session_baton_t *sess_baton = session->priv;
svn_ra_svn_conn_t *conn = sess_baton->conn;
+ svn_error_t *err;
path = reparent_path(session, path, pool);
@@ -3116,8 +3120,20 @@ ra_svn_get_deleted_rev(svn_ra_session_t *session,
SVN_ERR(handle_unsupported_cmd(handle_auth_request(sess_baton, pool),
N_("'get-deleted-rev' not implemented")));
- return svn_error_trace(svn_ra_svn__read_cmd_response(conn, pool, "r",
- revision_deleted));
+ err = svn_error_trace(svn_ra_svn__read_cmd_response(conn, pool, "r",
+ revision_deleted));
+ /* The protocol does not allow for a reply of SVN_INVALID_REVNUM directly.
+ Instead, a new enough server returns SVN_ERR_ENTRY_MISSING_REVISION to
+ indicate the answer to the query is SVN_INVALID_REVNUM. (An older server
+ closes the connection and returns SVN_ERR_RA_SVN_CONNECTION_CLOSED.) */
+ if (err && err->apr_err == SVN_ERR_ENTRY_MISSING_REVISION)
+ {
+ *revision_deleted = SVN_INVALID_REVNUM;
+ svn_error_clear(err);
+ }
+ else
+ SVN_ERR(err);
+ return SVN_NO_ERROR;
}
static svn_error_t *
diff --git a/subversion/libsvn_ra_svn/editorp.c b/subversion/libsvn_ra_svn/editorp.c
index 10c8a2b04a63..438bbfc4d490 100644
--- a/subversion/libsvn_ra_svn/editorp.c
+++ b/subversion/libsvn_ra_svn/editorp.c
@@ -118,7 +118,7 @@ make_token(char type,
char buffer[1 + SVN_INT64_BUFFER_SIZE];
buffer[0] = type;
len = 1 + svn__ui64toa(&buffer[1], eb->next_token++);
-
+
return svn_string_ncreate(buffer, len, pool);
}
diff --git a/subversion/libsvn_ra_svn/libsvn_ra_svn.pc.in b/subversion/libsvn_ra_svn/libsvn_ra_svn.pc.in
index 4d6768986f13..39666c0d1dd1 100644
--- a/subversion/libsvn_ra_svn/libsvn_ra_svn.pc.in
+++ b/subversion/libsvn_ra_svn/libsvn_ra_svn.pc.in
@@ -6,7 +6,7 @@ includedir=@includedir@
Name: libsvn_ra_svn
Description: Subversion SVN Protocol Repository Access Library
Version: @PACKAGE_VERSION@
-Requires: apr-util-@SVN_APR_MAJOR_VERSION@ apr-@SVN_APR_MAJOR_VERSION@
-Requires.private: libsvn_delta libsvn_subr
-Libs: -L${libdir} -lsvn_ra_svn @SVN_SASL_LIBS@
-Cflags: -I${includedir}
+Requires: apr-util-@SVN_APR_MAJOR_VERSION@, apr-@SVN_APR_MAJOR_VERSION@
+Requires.private: libsvn_delta, libsvn_subr
+Libs: -L${libdir} -lsvn_ra_svn-1 @SVN_SASL_LIBS@
+Cflags: -I${includedir}/subversion-1
diff --git a/subversion/libsvn_ra_svn/protocol b/subversion/libsvn_ra_svn/protocol
index dfa7bc4585ac..b067d8744d8c 100644
--- a/subversion/libsvn_ra_svn/protocol
+++ b/subversion/libsvn_ra_svn/protocol
@@ -342,7 +342,7 @@ second place for auth-request point as noted below.
stat
params: ( path:string [ rev:number ] )
response: ( ? entry:dirent )
- dirent: ( name:string kind:node-kind size:number has-props:bool
+ dirent: ( kind:node-kind size:number has-props:bool
created-rev:number [ created-date:string ]
[ last-author:string ] )
New in svn 1.2. If path is non-existent, an empty response is returned.