Browse code

Adjust the way tail_kvno (vno32) overrides kvno.

Xavier G authored on26/04/2020 14:02:10
Showing1 changed files

  • yamltab index 469a007..f61e444 100755
... ...
@@ -244,8 +244,8 @@ def enrich_keytab(keytab):
244 244
 				tail_kvno = struct.unpack('>I', record['tail'][0:4])[0]
245 245
 				if tail_kvno:
246 246
 					entry['tail_kvno'] = tail_kvno
247
-					# If kvno is zero, assume the one found in the tail is the one that matters:
248
-					if not entry['kvno']:
247
+					# tail_kvno overrides kvno if non-zero:
248
+					if entry['tail_kvno']:
249 249
 						entry['actual_kvno'] = entry['tail_kvno']
250 250
 			if 'actual_kvno' not in entry:
251 251
 				entry['actual_kvno'] = entry['kvno']