FreeCalypso > hg > fc-tourmaline
comparison src/ui/mfw/mfw_nma.c @ 188:92abb46dc1ba
src/ui/mfw/*.[ch]: rm trailing white space
author | Mychaela Falconia <falcon@freecalypso.org> |
---|---|
date | Tue, 19 Jan 2021 06:10:27 +0000 |
parents | 67bfe9f274f6 |
children |
comparison
equal
deleted
inserted
replaced
187:a33dd8a5dcc9 | 188:92abb46dc1ba |
---|---|
207 nreg_ind = (T_MMREG_DETACH_IND *)data; | 207 nreg_ind = (T_MMREG_DETACH_IND *)data; |
208 nm_aci_data.nreg_cause = nreg_ind->ps_cause; | 208 nm_aci_data.nreg_cause = nreg_ind->ps_cause; |
209 return FALSE; /* normal processing of ACI */ | 209 return FALSE; /* normal processing of ACI */ |
210 | 210 |
211 case MMREG_INFO_IND: | 211 case MMREG_INFO_IND: |
212 | 212 |
213 /* send this NITZ information to MMI | 213 /* send this NITZ information to MMI |
214 */ | 214 */ |
215 TRACE_FUNCTION(" case MMREG_INFO_IND: "); | 215 TRACE_FUNCTION(" case MMREG_INFO_IND: "); |
216 nm_nitz_info_ind((T_MMREG_INFO_IND *)data); | 216 nm_nitz_info_ind((T_MMREG_INFO_IND *)data); |
217 return FALSE; /* normal processing of ACI */ | 217 return FALSE; /* normal processing of ACI */ |
227 | 227 |
228 memcpy (&(mmr_nitz_ind->ntz), &(gmmreg_info_ind->net_time_zone),sizeof (T_net_time_zone)); | 228 memcpy (&(mmr_nitz_ind->ntz), &(gmmreg_info_ind->net_time_zone),sizeof (T_net_time_zone)); |
229 | 229 |
230 memcpy (&(mmr_nitz_ind->time), &(gmmreg_info_ind->net_time), sizeof(T_net_time)); | 230 memcpy (&(mmr_nitz_ind->time), &(gmmreg_info_ind->net_time), sizeof(T_net_time)); |
231 | 231 |
232 | 232 |
233 nm_nitz_info_ind(* mmr_nitz_ind ); | 233 nm_nitz_info_ind(* mmr_nitz_ind ); |
234 return FALSE; /* normal processing of ACI */ | 234 return FALSE; /* normal processing of ACI */ |
235 } | 235 } |
236 | 236 |
237 /* BEGIN ADD: Neptune alignment*/ | 237 /* BEGIN ADD: Neptune alignment*/ |
277 | 277 |
278 // x0066814 (Geetha), OMAPS00098351 (NITZ), Timezone info handling | 278 // x0066814 (Geetha), OMAPS00098351 (NITZ), Timezone info handling |
279 #ifdef GPRS | 279 #ifdef GPRS |
280 case GMMREG_INFO_IND: | 280 case GMMREG_INFO_IND: |
281 TRACE_FUNCTION(" case GMMREG_INFO_IND: "); | 281 TRACE_FUNCTION(" case GMMREG_INFO_IND: "); |
282 | 282 |
283 gmmreg_info_ind= (T_GMMREG_INFO_IND *)data; | 283 gmmreg_info_ind= (T_GMMREG_INFO_IND *)data; |
284 memcpy (&(mmr_nitz_ind.plmn), &(gmmreg_info_ind->plmn), sizeof(T_plmn)); | 284 memcpy (&(mmr_nitz_ind.plmn), &(gmmreg_info_ind->plmn), sizeof(T_plmn)); |
285 | 285 |
286 memcpy (&(mmr_nitz_ind.full_name),&(gmmreg_info_ind->full_net_name_gmm), sizeof (T_full_name)); | 286 memcpy (&(mmr_nitz_ind.full_name),&(gmmreg_info_ind->full_net_name_gmm), sizeof (T_full_name)); |
287 memcpy (&(mmr_nitz_ind.short_name),&(gmmreg_info_ind->short_net_name_gmm), sizeof (T_short_name)); | 287 memcpy (&(mmr_nitz_ind.short_name),&(gmmreg_info_ind->short_net_name_gmm), sizeof (T_short_name)); |
288 | 288 |
289 memcpy (&(mmr_nitz_ind.ntz), &(gmmreg_info_ind->net_time_zone),sizeof (T_ntz)); | 289 memcpy (&(mmr_nitz_ind.ntz), &(gmmreg_info_ind->net_time_zone),sizeof (T_ntz)); |
290 memcpy (&(mmr_nitz_ind.time), &(gmmreg_info_ind->net_time), sizeof(T_time)); | 290 memcpy (&(mmr_nitz_ind.time), &(gmmreg_info_ind->net_time), sizeof(T_time)); |
291 | 291 |
292 | 292 |
293 nm_nitz_info_ind(&mmr_nitz_ind); | 293 nm_nitz_info_ind(&mmr_nitz_ind); |
294 return FALSE; /* normal processing of ACI */ | 294 return FALSE; /* normal processing of ACI */ |
295 #endif | 295 #endif |
296 } | 296 } |
297 | 297 |
344 strcpy ((char *)numeric_name, ""); | 344 strcpy ((char *)numeric_name, ""); |
345 | 345 |
346 switch (format) | 346 switch (format) |
347 { | 347 { |
348 case COPS_FRMT_Numeric: | 348 case COPS_FRMT_Numeric: |
349 #ifndef NEPTUNE_BOARD | 349 #ifndef NEPTUNE_BOARD |
350 strcpy ((char *)numeric_name, (char *)oper); | 350 strcpy ((char *)numeric_name, (char *)oper); |
351 found = cmhMM_FindNumeric (&plmnDesc, (char *)oper); | 351 found = cmhMM_FindNumeric (&plmnDesc, (char *)oper); |
352 if (found) | 352 if (found) |
353 { | 353 { |
354 UBYTE length=strlen((const char*)plmnDesc.longName); | 354 UBYTE length=strlen((const char*)plmnDesc.longName); |
484 if ((network_entry->mnc & 0xf) EQ 0xf) | 484 if ((network_entry->mnc & 0xf) EQ 0xf) |
485 numeric_name[5] = '\0'; /* 2-digit-MNC */ | 485 numeric_name[5] = '\0'; /* 2-digit-MNC */ |
486 else | 486 else |
487 numeric_name[5] = ( network_entry->mnc & 0xf) + '0'; | 487 numeric_name[5] = ( network_entry->mnc & 0xf) + '0'; |
488 numeric_name[6] = '\0'; /* 3-digit-MNC */ | 488 numeric_name[6] = '\0'; /* 3-digit-MNC */ |
489 | 489 |
490 if (network_entry->longName) | 490 if (network_entry->longName) |
491 { | 491 { |
492 long_name->len = MINIMUM(LONG_NAME-1, strlen((char *)network_entry->longName)); | 492 long_name->len = MINIMUM(LONG_NAME-1, strlen((char *)network_entry->longName)); |
493 memcpy (long_name->data, network_entry->longName, long_name->len); | 493 memcpy (long_name->data, network_entry->longName, long_name->len); |
494 long_name->data[long_name->len] = '\0'; | 494 long_name->data[long_name->len] = '\0'; |
495 long_name->dcs = MFW_ASCII; | 495 long_name->dcs = MFW_ASCII; |
501 } | 501 } |
502 #else | 502 #else |
503 GLOBAL void sAT_PlusCOPSE(UBYTE *oper, UBYTE format, UBYTE *long_name, | 503 GLOBAL void sAT_PlusCOPSE(UBYTE *oper, UBYTE format, UBYTE *long_name, |
504 UBYTE *short_name, UBYTE *numeric_name) | 504 UBYTE *short_name, UBYTE *numeric_name) |
505 { | 505 { |
506 #ifndef NEPTUNE_BOARD | 506 #ifndef NEPTUNE_BOARD |
507 T_OPER_ENTRY plmnDesc; | 507 T_OPER_ENTRY plmnDesc; |
508 BOOL found; | 508 BOOL found; |
509 #else | 509 #else |
510 T_OPER_NTRY * network_entry; | 510 T_OPER_NTRY * network_entry; |
511 #endif | 511 #endif |
569 else | 569 else |
570 numeric_name[5] = ( plmnDesc.mnc & 0xf) + '0'; | 570 numeric_name[5] = ( plmnDesc.mnc & 0xf) + '0'; |
571 numeric_name[6] = '\0'; /* 3-digit-MNC */ | 571 numeric_name[6] = '\0'; /* 3-digit-MNC */ |
572 | 572 |
573 strncpy ((char *)short_name, plmnDesc.shrtName, SHORT_NAME-1); | 573 strncpy ((char *)short_name, plmnDesc.shrtName, SHORT_NAME-1); |
574 short_name[SHORT_NAME-1] = '\0'; | 574 short_name[SHORT_NAME-1] = '\0'; |
575 } | 575 } |
576 #else | 576 #else |
577 network_entry = cmhMM_FindName ((char *)oper, COPS_FRMT_Long); | 577 network_entry = cmhMM_FindName ((char *)oper, COPS_FRMT_Long); |
578 if (network_entry NEQ NULL) | 578 if (network_entry NEQ NULL) |
579 { | 579 { |
589 numeric_name[6] = '\0'; /* 3-digit-MNC */ | 589 numeric_name[6] = '\0'; /* 3-digit-MNC */ |
590 | 590 |
591 if (network_entry->shrtName) | 591 if (network_entry->shrtName) |
592 { | 592 { |
593 strncpy ((char *)short_name, (char *)network_entry->shrtName, SHORT_NAME-1); | 593 strncpy ((char *)short_name, (char *)network_entry->shrtName, SHORT_NAME-1); |
594 short_name[SHORT_NAME-1] = '\0'; | 594 short_name[SHORT_NAME-1] = '\0'; |
595 } | 595 } |
596 } | 596 } |
597 #endif | 597 #endif |
598 break; | 598 break; |
599 | 599 |
600 case COPS_FRMT_Short: | 600 case COPS_FRMT_Short: |
601 if (oper) | 601 if (oper) |
602 { | 602 { |
603 strncpy ((char *)short_name, (char *)oper, SHORT_NAME-1); | 603 strncpy ((char *)short_name, (char *)oper, SHORT_NAME-1); |
604 short_name[SHORT_NAME-1] = '\0'; | 604 short_name[SHORT_NAME-1] = '\0'; |
605 } | 605 } |
606 #ifndef NEPTUNE_BOARD | 606 #ifndef NEPTUNE_BOARD |
607 found = cmhMM_FindName (&plmnDesc, (char *)oper, COPS_FRMT_Short); | 607 found = cmhMM_FindName (&plmnDesc, (char *)oper, COPS_FRMT_Short); |
608 if (found) | 608 if (found) |
609 { | 609 { |
634 numeric_name[5] = '\0'; /* 2-digit-MNC */ | 634 numeric_name[5] = '\0'; /* 2-digit-MNC */ |
635 else | 635 else |
636 numeric_name[5] = ( network_entry->mnc & 0xf) + '0'; | 636 numeric_name[5] = ( network_entry->mnc & 0xf) + '0'; |
637 numeric_name[6] = '\0'; /* 3-digit-MNC */ | 637 numeric_name[6] = '\0'; /* 3-digit-MNC */ |
638 | 638 |
639 if (network_entry->longName) | 639 if (network_entry->longName) |
640 { | 640 { |
641 strncpy ((char *)long_name, (char *)network_entry->longName, LONG_NAME-1); | 641 strncpy ((char *)long_name, (char *)network_entry->longName, LONG_NAME-1); |
642 long_name[LONG_NAME-1] = '\0'; | 642 long_name[LONG_NAME-1] = '\0'; |
643 } | 643 } |
644 } | 644 } |