Mercurial > pt1.oyama
diff arib25/src/arib_std_b25.c @ 54:080414aa8f21
updated to arib25 0.2.4
author | Yoshiki Yazawa <yaz@honeyplanet.jp> |
---|---|
date | Sun, 13 Sep 2009 02:57:13 +0900 |
parents | 41a5481db56f |
children | 521d796003b2 |
line wrap: on
line diff
--- a/arib25/src/arib_std_b25.c Sun Sep 13 02:11:33 2009 +0900 +++ b/arib25/src/arib_std_b25.c Sun Sep 13 02:57:13 2009 +0900 @@ -408,6 +408,8 @@ static uint8_t *resync(uint8_t *head, uint8_t *tail, int32_t unit); static uint8_t *resync_force(uint8_t *head, uint8_t *tail, int32_t unit); +static uint32_t crc32(uint8_t *head, uint8_t *tail); + /*+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ interface method implementation ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++*/ @@ -568,6 +570,15 @@ extract_ts_header(&hdr, curr); crypt = hdr.transport_scrambling_control; pid = hdr.pid; + + if(hdr.transport_error_indicator != 0){ + /* bit error - append output buffer without parsing */ + if(!append_work_buffer(&(prv->dbuf), curr, 188)){ + r = ARIB_STD_B25_ERROR_NO_ENOUGH_MEMORY; + goto LAST; + } + goto NEXT; + } if( (pid == 0x1fff) && (prv->strip) ){ goto NEXT; @@ -589,6 +600,9 @@ if(prv->map[pid].type == PID_MAP_TYPE_OTHER){ dec = (DECRYPTOR_ELEM *)(prv->map[pid].target); + }else if( (prv->map[pid].type == 0) && + (prv->decrypt.count == 1) ){ + dec = prv->decrypt.head; }else{ dec = NULL; } @@ -996,7 +1010,7 @@ head = prv->sbuf.head; tail = prv->sbuf.tail; - + buf = head; memset(count, 0, sizeof(count)); @@ -1795,6 +1809,15 @@ crypt = hdr.transport_scrambling_control; pid = hdr.pid; + if(hdr.transport_error_indicator != 0){ + /* bit error - append output buffer without parsing */ + if(!append_work_buffer(&(prv->dbuf), curr, 188)){ + r = ARIB_STD_B25_ERROR_NO_ENOUGH_MEMORY; + goto LAST; + } + goto NEXT; + } + if( (pid == 0x1fff) && (prv->strip) ){ /* strip null(padding) stream */ goto NEXT;