Summary:ASTERISK-15639: [patch] Fix portability bit fields and make "mfcr2_immediate_accept" work again
Reporter:Humberto Figuera (korihor)Labels:
Date Opened:2010-02-16 12:54:33.000-0600Date Closed:2010-03-03 08:59:15.000-0600
Versions:Frequency of
Environment:Attachments:( 0) chan_dahdi.c_fix_portability_bit_fields_and_make_immediate_accept_work_again.patch
Description:First, because in C the "bit fields" are "implementation-defined" when a member is declared as type "int". It is recommended to explicitly specify "signed" or "unsigned" on this members for portability.

Second, the variables "get_ani_first", "skip_category_request", "immediate_accept" contain over his life three possible values: -1, 0, 1. They therefore have to be members type "signed int" 2-bit (: 2). The rest can only be 0 or 1, so they are "unsigned int" 1-bit (: 1).


Without this patch, "mfcr2_immediate_accept" does not work.
Comments:By: Moises Silva (moy) 2010-02-19 13:01:04.000-0600

Fixed in trunk rev 248003
Fixed in 1.6.2 248005

Thanks korihor!

lmadsen: This bug can now be closed :-)

By: Leif Madsen (lmadsen) 2010-03-03 08:59:04.000-0600

moy: thanks for the commit! In the future you can use the Commit Template to close these issues from the commit message.

By: Leif Madsen (lmadsen) 2010-03-03 08:59:15.000-0600

Fixed per moy.