/[projects]/smsdaemon/SmsPdu.cpp
ViewVC logotype

Diff of /smsdaemon/SmsPdu.cpp

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 73 by torben, Fri Jun 13 09:09:36 2008 UTC revision 77 by torben, Fri Jun 13 21:15:00 2008 UTC
# Line 13  Line 13 
13  #include "common.h"  #include "common.h"
14  #include "util.h"  #include "util.h"
15    
 #include <iostream>  
16    
17  using namespace std;  using namespace std;
18    
   
19  namespace SmsPdu  namespace SmsPdu
20  {  {
21    
# Line 313  namespace SmsPdu Line 311  namespace SmsPdu
311                  if (UDHI)                  if (UDHI)
312                  {                  {
313                          int udh_len = (*it++);                          int udh_len = (*it++);
                         cout << "UDH_LEN:" << udh_len << endl;  
314                          it += udh_len; //just ignore the User Data Header                          it += udh_len; //just ignore the User Data Header
315                          data_len -= udh_len;                          data_len -= udh_len;
316    
317                          shift_start = udh_len+1; //make the 8to7bit decode start with the right shift level                          shift_start = udh_len+1; //make the 8to7bit decode start with the right shift level
318                  }                  }
                 cout << hex<< (int)(*it) << endl;;  
319    
320    
321                  vector<unsigned char> user_data;                  vector<unsigned char> user_data;
322                  user_data.insert(user_data.end(), it, it+data_len);                  user_data.insert(user_data.end(), it, it+data_len);
323                                    
324                  result.message = Decode8to7bit(user_data, shift_start);                  result.message = Decode8to7bit(user_data, shift_start).substr(0,data_len);
325                                    
326    
327                  return result;                  return result;

Legend:
Removed from v.73  
changed lines
  Added in v.77

  ViewVC Help
Powered by ViewVC 1.1.20