aboutsummaryrefslogtreecommitdiff
path: root/vcs-svn/svndump.c
diff options
context:
space:
mode:
Diffstat (limited to 'vcs-svn/svndump.c')
-rw-r--r--vcs-svn/svndump.c13
1 files changed, 9 insertions, 4 deletions
diff --git a/vcs-svn/svndump.c b/vcs-svn/svndump.c
index 11c59f18b..b1f416106 100644
--- a/vcs-svn/svndump.c
+++ b/vcs-svn/svndump.c
@@ -217,9 +217,7 @@ static void handle_node(void)
*/
static const char *const empty_blob = "::empty::";
const char *old_data = NULL;
-
- if (node_ctx.text_delta)
- die("text deltas not supported");
+ uint32_t old_mode = REPO_MODE_BLB;
if (node_ctx.action == NODEACT_DELETE) {
if (have_text || have_props || node_ctx.srcRev)
@@ -255,6 +253,7 @@ static void handle_node(void)
if (mode != REPO_MODE_DIR && type == REPO_MODE_DIR)
die("invalid dump: cannot modify a file into a directory");
node_ctx.type = mode;
+ old_mode = mode;
} else if (node_ctx.action == NODEACT_ADD) {
if (type == REPO_MODE_DIR)
old_data = NULL;
@@ -289,8 +288,14 @@ static void handle_node(void)
fast_export_modify(node_ctx.dst.buf, node_ctx.type, old_data);
return;
}
+ if (!node_ctx.text_delta) {
+ fast_export_modify(node_ctx.dst.buf, node_ctx.type, "inline");
+ fast_export_data(node_ctx.type, node_ctx.textLength, &input);
+ return;
+ }
fast_export_modify(node_ctx.dst.buf, node_ctx.type, "inline");
- fast_export_data(node_ctx.type, node_ctx.textLength, &input);
+ fast_export_blob_delta(node_ctx.type, old_mode, old_data,
+ node_ctx.textLength, &input);
}
static void begin_revision(void)