changeset 314:5c4d68911dd3 trim

date-stamp still wrong
author Henry S. Thompson <ht@inf.ed.ac.uk>
date Tue, 23 Dec 2025 17:14:19 +0000
parents c05293f9d958
children 6c586bee6a50
files lib/python/cc/lmh/shrink.py
diffstat 1 files changed, 5 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/lib/python/cc/lmh/shrink.py	Tue Dec 23 16:59:32 2025 +0000
+++ b/lib/python/cc/lmh/shrink.py	Tue Dec 23 17:14:19 2025 +0000
@@ -21,14 +21,17 @@
     (os1,os2)=bb[1:].split(b',')
     kl=int(os1)
     ll=int(os2)
+    print(od,dp,dpl,file=sys.stderr)
     for i in range(dpl):
       if od[i] != dp[i]:
         break
+    else:
+      i+=1
     if i > 0:
-      nd = od[i-1:]
+      nd = od[i:]
     else:
       nd = od
-    print(od,nd,file=sys.stderr)
+    print(i,od,nd,file=sys.stderr)
     ol = oe[-ll:]
     nli = int(ol)
     int.to_bytes(nli,4)