Changeset 1315 for proto/FIX/fix.py


Ignore:
Timestamp:
Aug 17, 2011, 10:24:55 PM (8 years ago)
Author:
cameron
Message:

Negated SOH for shift-in of 1

File:
1 edited

Legend:

Unmodified
Added
Removed
  • proto/FIX/fix.py

    r1314 r1315  
    4646def Parse_fields(fix_lex, fix_callout):
    4747        # Assume for now that all SOHs are field separators, not data.
    48         marker = fix_lex.SOH
    49         header1 = bitutil.Advance(marker)
     48        # Use negated SOH stream to shift in a 1 at start-of-file.
     49        # shift out a 0 at end of file.
     50        marker = ~bitutil.Advance(~fix_lex.SOH)
     51        header1 = marker
    5052        header2 = bitutil.ScanThru(marker, fix_lex.Digit)
    5153        error1 = header1 & fix_lex.Zero
Note: See TracChangeset for help on using the changeset viewer.