Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

iOS crash on Bugfender.Log with <null> tag #2

Open
novavision opened this issue Oct 8, 2023 · 3 comments
Open

iOS crash on Bugfender.Log with <null> tag #2

novavision opened this issue Oct 8, 2023 · 3 comments

Comments

@novavision
Copy link

novavision commented Oct 8, 2023

iOS app crashes each time on Bugfender.Log with tag set to null.
Android is OK.
Unity 2022.3.10f1
iOS device: iPhone 7, 15.7.9

log here

@jgimenez
Copy link
Member

jgimenez commented Oct 9, 2023

Hi @novavision , could you please share a code sample to reproduce the problem? Is it really a problem or you're passing a null where a string is supposed to be passed?

@novavision
Copy link
Author

novavision commented Oct 9, 2023

Well, it's pretty common practice to use null in string parameters because in C# normally used string.IsNullOrEmpty check.
Bugfender.Log(Bugfender.LogLevel.Debug, tag, message);
In cases, when you don't want to add the tag could be 2 options - string.empty or null. Again, maybe that's how you planned to make it work, but passing null as a parameter on Android works fine.

Not a big problem, however it took some time for me to define that is the reason of crashes

@jgimenez
Copy link
Member

jgimenez commented Oct 11, 2023

I see, thanks.

I agree the behavior should at least be consistent across platforms. Also, the iOS SDK accepts a nil tag, just I see the glue code assumes it is not: https://github.com/bugfender/BugfenderSDK-Unity/blob/main/Assets/Plugins/iOS/BugfenderBridge.mm#L50

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants