firebase / firebase/quickstart-unity
Crash on iPhone 6 on iOS 12 with Realtime Database
- Dominant language
- C#
- Stars
- 923
- Forks
- 456
- PR merge metrics
- No merged PRs in 30d
Description
### [REQUIRED] Please fill in the following fields:
* Unity editor version: 2021.3.32f1
* Firebase Unity SDK version: 11.6.0
* Source you installed the SDK: Unity package manager via tgz
* Problematic Firebase Component: Realtime database
* Other Firebase Components in use: None
* Additional SDKs you are using: None
* Platform you are using the Unity editor on: MacOS 14.0 with xCode version 15.0.1
* Platform you are targeting: iPhone 6 iOS 12.5.7
* Scripting Runtime: IL2CPP
### [REQUIRED] Please describe the issue here:
When trying to register for a value changed in the realtime database, the app crashes on the iPhone 6. This only occurs on the iPhone 6 and not on later iPhones. When the app crashes, xcode outputs a cryptic message:
`0x100aa4000: .long 0xfeedfacf ; unknown opcode`
#### Steps to reproduce:
- Install firebase through the package manager
- Add GoogleService-Info to the project
- Add the script below (see following section)
- Build the project through xCode
- Notice the crash on iPhone 6.
- Notice that the crash does not occur on more 'modern' iPhones, which my collegues have
I was also able to reproduce this issue in the samples project.
I also tried downgrading the firebase SDK to 10.6.0 and the issue also occured here.
#### Relevant Code:
```
public void ReadSomeValueChange()
{
string dataBaseUrl = "https://.firebasedatabase.app/";
Debug.Log("Before getting instance");
var dataBase = FirebaseDatabase.GetInstance(dataBaseUrl);
Debug.Log("Before getting reference");
var somePath = dataBase.GetReference("/test");
Debug.Log("Before registering to value changed");
somePath.ValueChanged += HandleValueChanged; // APP CRASHES HERE
}
private void HandleValueChanged(object sender, ValueChangedEventArgs args)
{
// app does not reach this line
Debug.Log("Value changed");
}
```
Contributor guide
Assessment
This issue has not been assessed yet.