Last active
September 6, 2015 16:24
-
-
Save nijikon/b9bc54002cceb395a825 to your computer and use it in GitHub Desktop.
rdiff-backup_librsyncmodule.c.patch
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--- a/_librsyncmodule.c.orig 2015-09-06 18:16:56.000000000 +0200 | |
+++ b/_librsyncmodule.c 2015-09-06 18:19:13.000000000 +0200 | |
@@ -58,9 +58,13 @@ | |
sm = PyObject_New(_librsync_SigMakerObject, &_librsync_SigMakerType); | |
if (sm == NULL) return NULL; | |
sm->x_attr = NULL; | |
- | |
- sm->sig_job = rs_sig_begin((size_t)blocklen, | |
- (size_t)RS_DEFAULT_STRONG_LEN); | |
+ #ifdef RS_DEFAULT_STRONG_LEN /* librsync < 1.0.0 */ | |
+ sm->sig_job = rs_sig_begin((size_t)blocklen, | |
+ (size_t)RS_DEFAULT_STRONG_LEN); | |
+ #else /* librsync >= 1.0.0 */ | |
+ sm->sig_job = rs_sig_begin((size_t)blocklen, | |
+ (size_t)8, RS_MD4_SIG_MAGIC); | |
+ #endif | |
return (PyObject*)sm; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment