@@ -103,26 +103,6 @@ static void processAccessList(txContext_t *context) {
103
103
}
104
104
}
105
105
106
- static void processType (txContext_t * context ) {
107
- if (context -> currentFieldIsList ) {
108
- PRINTF ("Invalid type for RLP_TYPE\n" );
109
- THROW (EXCEPTION );
110
- }
111
- if (context -> currentFieldLength > MAX_INT256 ) {
112
- PRINTF ("Invalid length for RLP_TYPE\n" );
113
- THROW (EXCEPTION );
114
- }
115
- if (context -> currentFieldPos < context -> currentFieldLength ) {
116
- uint32_t copySize =
117
- MIN (context -> commandLength , context -> currentFieldLength - context -> currentFieldPos );
118
- copyTxData (context , NULL , copySize );
119
- }
120
- if (context -> currentFieldPos == context -> currentFieldLength ) {
121
- context -> currentField ++ ;
122
- context -> processingField = false;
123
- }
124
- }
125
-
126
106
static void processChainID (txContext_t * context ) {
127
107
if (context -> currentFieldIsList ) {
128
108
PRINTF ("Invalid type for RLP_CHAINID\n" );
@@ -321,14 +301,6 @@ static bool processEIP1559Tx(txContext_t *context) {
321
301
switch (context -> currentField ) {
322
302
case EIP1559_RLP_CONTENT : {
323
303
processContent (context );
324
- if ((context -> processingFlags & TX_FLAG_TYPE ) == 0 ) {
325
- context -> currentField ++ ;
326
- }
327
- break ;
328
- }
329
- // This gets hit only by Wanchain
330
- case EIP1559_RLP_TYPE : {
331
- processType (context );
332
304
break ;
333
305
}
334
306
case EIP1559_RLP_CHAINID : {
@@ -377,13 +349,6 @@ static bool processEIP2930Tx(txContext_t *context) {
377
349
switch (context -> currentField ) {
378
350
case EIP2930_RLP_CONTENT :
379
351
processContent (context );
380
- if ((context -> processingFlags & TX_FLAG_TYPE ) == 0 ) {
381
- context -> currentField ++ ;
382
- }
383
- break ;
384
- // This gets hit only by Wanchain
385
- case EIP2930_RLP_TYPE :
386
- processType (context );
387
352
break ;
388
353
case EIP2930_RLP_CHAINID :
389
354
processChainID (context );
@@ -420,13 +385,6 @@ static bool processLegacyTx(txContext_t *context) {
420
385
switch (context -> currentField ) {
421
386
case LEGACY_RLP_CONTENT :
422
387
processContent (context );
423
- if ((context -> processingFlags & TX_FLAG_TYPE ) == 0 ) {
424
- context -> currentField ++ ;
425
- }
426
- break ;
427
- // This gets hit only by Wanchain
428
- case LEGACY_RLP_TYPE :
429
- processType (context );
430
388
break ;
431
389
case LEGACY_RLP_NONCE :
432
390
processNonce (context );
@@ -592,16 +550,12 @@ static parserStatus_e processTxInternal(txContext_t *context) {
592
550
PRINTF ("end of here\n" );
593
551
}
594
552
595
- parserStatus_e processTx (txContext_t * context ,
596
- const uint8_t * buffer ,
597
- uint32_t length ,
598
- uint32_t processingFlags ) {
553
+ parserStatus_e processTx (txContext_t * context , const uint8_t * buffer , uint32_t length ) {
599
554
parserStatus_e result ;
600
555
BEGIN_TRY {
601
556
TRY {
602
557
context -> workBuffer = buffer ;
603
558
context -> commandLength = length ;
604
- context -> processingFlags = processingFlags ;
605
559
result = processTxInternal (context );
606
560
PRINTF ("result: %d\n" , result );
607
561
}
0 commit comments