# # patch "ChangeLog" # from [08edad29c22077ab1880b0472c28ff9b719b5ba2] # to [d7d67824b355065c07adcf31a123e7a14cf48155] # # patch "diff_patch.cc" # from [e798174667fdbb10359025f4b050b0b1c017705c] # to [c080a1bd6428d24243c0fc224414be6eb0fb7949] # --- ChangeLog +++ ChangeLog @@ -1,9 +1,14 @@ 2005-04-15 Sebastian Spaeth * ui.cc: print byte progress to one decimal place in k or M. * netsync.cc: update dot ticker every 1024 bytes. +2005-04-15 Olivier Andrieu + + * diff_patch.cc(guess_binary): do not use '\x00' as first + character of a C string ... + 2005-04-15 Matt Johnston * change_set.cc (confirm_proper_tree): use bitsets rather than maps @@ -2756,7 +2761,7 @@ * AUTHORS: Mention Wojciech and Neil. * revision.cc (calculate_ancestors_from_graph): Make non-recursive. -2005-01-17 Wojciech Miłkowski +2005-01-17 Wojciech Miłkowski * std_hooks.lua: Teach about meld. --- diff_patch.cc +++ diff_patch.cc @@ -25,7 +25,8 @@ { // these do not occur in ASCII text files // FIXME: this heuristic is (a) crap and (b) hardcoded. fix both these. - if (s.find_first_of("\x00\x01\x02\x03\x04\x05\x06\x0e\x0f" + if (s.find_first_of('\x00') != string::npos || + s.find_first_of("\x01\x02\x03\x04\x05\x06\x0e\x0f" "\x10\x11\x12\x13\x14\x15\x16\x17\x18" "\x19\x1a\x1c\x1d\x1e\x1f") != string::npos) return true;