Hello,
It is more than probably an old error of mine that only comes to the surface from today. Please, I would like to be sure the workaround I put is the really one I had to use.
I have registered a broadcast receiver (SMS data) in the manifest, pointing to a service. So the service is started each time a SMS data is received. But in the same service, I am handling the data. When a new SMS is received while the data from a previous SMS is processed, the service crashes (about a list not initialized, the one containing the intent information ~~~ probably the old ones). Till today, it has worked without any problem and the only thing I changed was to try the app on Marshmallow.
So, I think that I have not well thought about the fact that the main process was working and that the system won't wait to restart the service while it is running. My workaround is now to create a class and initialize it for each SMS data received.
For the moment I have no more crash but, I would like to be sure to have used the correct solution.
Many thanks
It is more than probably an old error of mine that only comes to the surface from today. Please, I would like to be sure the workaround I put is the really one I had to use.
I have registered a broadcast receiver (SMS data) in the manifest, pointing to a service. So the service is started each time a SMS data is received. But in the same service, I am handling the data. When a new SMS is received while the data from a previous SMS is processed, the service crashes (about a list not initialized, the one containing the intent information ~~~ probably the old ones). Till today, it has worked without any problem and the only thing I changed was to try the app on Marshmallow.
So, I think that I have not well thought about the fact that the main process was working and that the system won't wait to restart the service while it is running. My workaround is now to create a class and initialize it for each SMS data received.
For the moment I have no more crash but, I would like to be sure to have used the correct solution.
Many thanks