Changeset 1314


Ignore:
Timestamp:
Aug 17, 2011, 6:19:54 PM (8 years ago)
Author:
cameron
Message:

Fixes

Location:
proto/FIX
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • proto/FIX/fix.py

    r1313 r1314  
    2222
    2323class Fix_callout():
    24         Header_end
     24        Header_end = 0
    2525
    2626def Classify_bytes(basis_bits, fix_lex): 
     
    3131        temp5 = (basis_bits.bit_7 &~ basis_bits.bit_6)
    3232        temp6 = (temp5 &~ temp4)
    33         SOH = (temp6 &~ temp3)
     33        fix_lex.SOH = (temp6 &~ temp3)
    3434        temp7 = (basis_bits.bit_2 & basis_bits.bit_3)
    3535        temp8 = (temp7 &~ temp1)
    3636        temp9 = (basis_bits.bit_4 & basis_bits.bit_5)
    3737        temp10 = (temp9 & temp5)
    38         Equals = (temp8 & temp10)
     38        fix_lex.Equals = (temp8 & temp10)
    3939        temp11 = (basis_bits.bit_5 | basis_bits.bit_6)
    4040        temp12 = (basis_bits.bit_4 & temp11)
    41         Digit = (temp8 &~ temp12)
     41        fix_lex.Digit = (temp8 &~ temp12)
    4242        temp13 = (basis_bits.bit_6 | basis_bits.bit_7)
    4343        temp14 = (temp4 | temp13)
    44         Zero = (temp8 &~ temp14)
     44        fix_lex.Zero = (temp8 &~ temp14)
    4545
    46 def parse_fields(fix_lex, fix_callout):
     46def Parse_fields(fix_lex, fix_callout):
    4747        # Assume for now that all SOHs are field separators, not data.
    48         marker = SOH
     48        marker = fix_lex.SOH
    4949        header1 = bitutil.Advance(marker)
    50         header2 = bitutil.ScanThru(marker, Digit)
    51         error1 = header1 & Zero
     50        header2 = bitutil.ScanThru(marker, fix_lex.Digit)
     51        error1 = header1 & fix_lex.Zero
    5252        error2 = header1 & header2
    53         error3 = header2 &~ Equals
     53        error3 = header2 &~ fix_lex.Equals
    5454        error = error1 | error2 | error3
    5555        if error:
    56                 error_tracker.Note_error("Potential error in header field", error)
     56                error_tracker.NoteError("Potential error in header field", error)
    5757        fix_callout.Header_end = header2
    5858
     
    6060        Classify_bytes(basis_bits, fix_lex)
    6161
    62         parse_fields(fix_lex, fix_callout)
     62        Parse_fields(fix_lex, fix_callout)
    6363
    6464
  • proto/FIX/fix_template.cpp

    r1313 r1314  
    1616
    1717#include "../lib/carryQ.h"
    18 #include "xmldecl.h"
    1918
    2019#include "../lib/perflib/perfsec.h"
     
    131130          s2p_do_block((BytePack *) &srcbuf[block_base], basis_bits);
    132131          @block_stmts
    133           postprocess_do_block(lex, ctCDPI_Callouts, ref_Callouts, check_streams, chars_avail);
     132          postprocess_do_block(fix_lex, fix_callout, chars_avail);
    134133      }
    135134      PERF_SEC_END(parser_timer, chars_avail);
     
    153152          s2p_do_block((BytePack *) &srcbuf[block_pos], basis_bits);
    154153          @block_stmts
    155           postprocess_do_block(fix_lex, fix_callout);
     154          postprocess_do_block(fix_lex, fix_callout, chars_avail);
    156155          block_pos += BLOCK_SIZE;
    157156          remaining -= BLOCK_SIZE;
     
    162161          s2p_do_final_block((BytePack *) &srcbuf[block_pos], basis_bits, EOF_mask);
    163162          @final_block_stmts
    164           postprocess_do_block(fix_lex, fix_callout);
     163          postprocess_do_block(fix_lex, fix_callout, chars_avail);
    165164    }
    166165    buf_pos += chars_avail;
Note: See TracChangeset for help on using the changeset viewer.