sigil-os 0ffa8cf corrects an arithmetic error in the RELAY_WIRE_TAG constant in cc0/srdx_relay.sg. The tag was hardcoded as 1381256521 but 0x52454C59 ("RELY" in ASCII) is 1380273241. The mismatch caused relay header validation to fail when the viewer attempted to decode frames — the relay emitted tag 0x52454C59 on the wire, but the constant used in comparisons was wrong. Caught by Sigil-Code review. QEMU PASS with corrected value.
The bug
RELAY_WIRE_TAG mismatch
RELAY_WIRE_TAG is the 4-byte magic used in the 8-byte relay header: [seq:u16 LE] [enc_len:u16 LE] [0x59, 0x4C, 0x45, 0x52] = "RELY" in little-endian. The bytes written to the wire were correct (poke8 with 0x52/0x45/0x4C/0x59 for 'R','E','L','Y'). But the constant used for comparison in srdx_wire_raw_send / viewer-side decode was 1381256521 instead of 1380273241. The difference: 1381256521 = 0x524F4C59 (has 'O' = 0x4F in byte 2 instead of 'E' = 0x45). The hex arithmetic for 'R'=0x52, 'E'=0x45, 'L'=0x4C, 'Y'=0x59 assembled into a LE u32 gives 0x52454C59 = 1380273241.Fix
cc0/srdx_relay.sg
One-line change:
RELAY_WIRE_TAG changed from 1381256521 to 1380273241. No behavioral change to the wire format — the bytes emitted were always correct. The fix aligns the comparison constant with the actual wire bytes. QEMU PASS re-run after fix confirms relay header validation succeeds.