Sometimes my app don't wake up when it's in background state on iOS7

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi everyone,

today I've done a little research on the issue of incoming calls in the 
background on iOS. We're getting a lot of negative feedback since the 
introduction of iOS 7.

| sometimes my app won't wake up after it goes to background, however,
| sometimes it will.

I get the impression, that it depends on the device. We have an iPhone 5 
and an iPhone 5S where almost no call is signalled when the app is in the 
background, while another iPhone 5S and an iPhone 4S running the exact 
same app work as expected. All devices run iOS 7.

There was a thread back in December on this list about background 
signalling (http://comments.gmane.org/gmane.comp.voip.pjsip/17912) but to 
be honest, I don't think the guys are on the right track. As far as I 
understood, the incoming INVITE is received on an already connected TCP 
socket, and PJSIP is marking that socket fine with 
kCFStreamNetworkServiceTypeVoIP. Maybe there is a misunderstanding on my 
side?

Anyway, I was digging up good old printf-debugging and logging the socket 
descriptor that is marked as ServiceTypeVoIP (or the CFStream associated 
with that socket, to be correct) - i.e. in 
activesock_create_iphone_os_stream() in activesock.c.
On the other hand I was printing the socket that the actual recv() is 
called on - i.e. in pj_sock_recv() in sock_bsd.c.

They match. Always. Even on the devices the error is always reproducible 
with. In case the call is not signalled while the app is in the 
background, recv() is called right in the moment, the app is woken up by 
me bringing it into the foreground. Can anyone confirm that? Just as if 
iOS forgets that this is a socket marked for background VoIP operation...

That together with the observation, that up to iOS 6 everything worked as 
expected, and the fact that calls in the background do work on some iOS 7 
devices with the exact same app bundle, leads me to the assumption, that 
this might simply be a bug in iOS 7.

I just wanted to check back with you guys before opening a bug report at 
Apple.
Any thoughts? Did I miss something?

Thanks,
Sebastian.



[Index of Archives]     [Asterisk Users]     [Asterisk App Development]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Security]     [Bugtraq]     [Linux]     [Linux OMAP]     [Linux MIPS]     [Linux API]
  Powered by Linux