1
0
mirror of https://github.com/sqlite/sqlite.git synced 2025-07-29 08:01:23 +03:00

Fix a bug in the wal.test script so that it works on big-endian systems.

FossilOrigin-Name: 40fe9088fb73eee7b37b574a1dda422266a58638
This commit is contained in:
drh
2012-05-11 20:43:47 +00:00
parent 26d8b0fb49
commit ed1d84e395
3 changed files with 12 additions and 11 deletions

View File

@ -1223,10 +1223,11 @@ proc logcksum {ckv1 ckv2 blob} {
upvar $ckv1 c1
upvar $ckv2 c2
set scanpattern I*
if {$::tcl_platform(byteOrder) eq "littleEndian"} {
set scanpattern i*
}
# Since the magic number at the start of the -wal file header is
# 931071618 that indicates that the content should always be read as
# little-endian.
#
set scanpattern i*
binary scan $blob $scanpattern values
foreach {v1 v2} $values {