# HG changeset patch # User Mychaela Falconia # Date 1528962181 0 # Node ID e9e72ec7b318865a9dbd94012911a0db8c5ae0b5 # Parent 5e39123540e63a3747330a60ef016bca042639cc aci2: Openmoko's SMS memory full bogon removed diff -r 5e39123540e6 -r e9e72ec7b318 src/aci2/aci/cmh_smsr.c --- a/src/aci2/aci/cmh_smsr.c Thu Jun 14 06:04:54 2018 +0000 +++ b/src/aci2/aci/cmh_smsr.c Thu Jun 14 07:43:01 2018 +0000 @@ -1022,7 +1022,24 @@ TRACE_EVENT_P1("MNSMS_ERROR_IND: 0x%4.4X", (int)mnsms_error_ind->cause); -/* send CMS error code for SMS memory full */ +/* + * The following piece of code has been added by Openmoko and then + * subsequently removed in FC Magnetite once I saw what it really does. + * Apparently OM were too incompetent to figure out how to use the + * existing SMS memory full/available notification mechanism by way + * of AT+CMER configuration and +CIEV unsolicited responses, and + * instead they added the following hack that sends a +CMS ERROR + * response (always with a numeric code, even if AT+CMEE is set to 2) + * as an unsolicited notification response on the memory full event. + * + * This code is bogus because it sends the unsolicited response string + * out by calling io_sendMessage() with a hard-coded source ID (!), + * and then adds to the bogosity by calling rCI_PlusCMS() in a context + * in which it does not expect to be called, causing further breakage + * in there. + */ + +#if 0 if(mnsms_error_ind->cause == SMS_CAUSE_MEM_FULL) { char *sa; @@ -1032,6 +1049,7 @@ ACI_MFREE(sa); rCI_PlusCMS ( 0, CMS_ERR_MemFull, NULL ); } +#endif if( (mnsms_error_ind->cause != SMS_CAUSE_MEM_FULL) && (mnsms_error_ind->cause != SMS_CAUSE_MEM_AVAIL) )