When SMSLib is reading  PDU Messages get a exception trying to parser
message '+CMS ERROR: 500' from the modem.

==============================
// the error occurs when line variable ==  '+CMS ERROR: 500'

Class = org.smslib.modem.ModemGateway.class
Method = private void readMessagesPDU(Collection<InboundMessage>
msgList, MessageClasses messageClass, int myLimit) throws
TimeoutException, GatewayException, IOException, InterruptedException

Lines = from 535 to 556.


==========================================================================
                                        if (line == null) break;
                                        line = line.trim();
                                        if (line.length() <= 0 || 
line.equalsIgnoreCase("OK")) break;
                                        if (line.length() <= 0 || 
line.equalsIgnoreCase("ERROR")) break;


                                        i = line.indexOf(':');
                                        j = line.indexOf(',');
                                        memIndex = 0;
                                        try
                                        {
                                                memIndex = 
Integer.parseInt(line.substring(i + 1, j).trim());
                                        }
                                        catch (NumberFormatException e)
                                        {
                                                // TODO: What to do here?
                                                
Logger.getInstance().logWarn("Incorrect Memory Index number
parsed!", e, getGatewayId());
                                        }
====================================================================================

Modem Information:
  Manufacturer: ZTE CORPORATION
  Model: MF100
  SIM IMSI: ** MASKED **

I had to kack the line to add that condition. that is my solution by
now...

Is this a possible bug???

salute,

-- 
You received this message because you are subscribed to the Google Groups 
"SMSLib Discussion Group" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/smslib?hl=en.

Reply via email to