Search Issue Tracker
Won't Fix
Votes
0
Found in [Package]
1.0.11
Issue ID
ULOG-15
Regression
Yes
Crash on "UnsafeUtility_CUSTOM_MemCpy" when using Asian alphabets in the "Log.Debug" function
How to reproduce:
1. Open the attached “IN-52317.zip” Project
2. Open the “SampleScene”
3. Enter Play mode
Expected result: Play Mode is entered successfully
Actual result: Crash
Reproducible with: 1.0.0-exp.7 (2022.3.8f1), 1.0.14 (2022.3.8f1, 2023.1.11f1, 2023.2.0b7, 2023.3.0a3)
Not reproducible with: 0.51.1-preview.21 (2021.3.30f1, 2022.3.8f1)
Couldn’t test with: 1.0.0-exp.6(2022.3.8f1) - Errors related to Burst Tests
Reproduced on: macOS Ventura 13.5 (Intel), Windows 11 (User Reported)
Not reproduced on: No other environment tested
Notes:
- Reproducible on a new Project
- Issue is not reproducible with Debug.Log, hence the issue is caused by the Logging package
- Reproducible with Korean, Japanese, and Chinese alphabets
- Not reproducible with Arabic, Russian, and Lithuanian alphabets
- Some versions may throw an error about un-safe code, to disable this error turn on the “Allow ‘unsafe’ Code” setting in the (Player Settings → Other Settings → Script Compilation) Section
- Another issue encountered with downgrading the Logging package is the issue discussed on the forums: [https://forum.unity.com/threads/error-after-adding-in-unity-netcode-package-to-unity-2022-3-lts.1443034/]
First few lines of the Stack Trace:
{\{0x00007ff7432595d5 (Unity) UnsafeUtility_CUSTOM_MemCpy }}
{\{0x0000021bfc228bd7 (Mono JIT Code) (wrapper managed-to-native) Unity.Collections.LowLevel.Unsafe.UnsafeUtility:MemCpy (void*,void*,long) }}
{\{0x0000021c26088ab3 (Mono JIT Code) Unity.Logging.Builder:BuildMessage (byte*,int,Unity.Logging.LogMemoryManager&) (at ./Library/PackageCache/com.unity.logging@1.0.14/Runtime/TextLogger/TextBuilder.cs:390) }}
{\{0x0000021c2608848b (Mono JIT Code) Unity.Logging.Builder:BuildMessage<Unity.Collections.LowLevel.Unsafe.UnsafeText> (Unity.Collections.LowLevel.Unsafe.UnsafeText&,Unity.Logging.LogMemoryManager&) (at ./Library/PackageCache/com.unity.logging@1.0.14/Runtime/TextLogger/TextBuilder.cs:340) }}
{\{0x0000021c2608754b (Mono JIT Code) Unity.Logging.Builder:BuildMessage (string,Unity.Logging.LogMemoryManager&) (at ./Library/PackageCache/com.unity.logging@1.0.14/Runtime/TextLogger/TextBuilder.cs:306) }}
{{0x0000021c26086dd3 (Mono JIT Code) Unity.Logging.Log:Debug (string) (at C:/Projects/UnityLoggingTest/MainLoggingGenerator/LoggingSourceGenerator/Assembly-CSharp_TextLoggerMethods_Gen.cs:256)}}
Add comment
All about bugs
View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.
Latest issues
- [Windows] Crash on GetManagerFromContext when video is playing and creating High Definition 3D Projects after FMOD failed to switch back to normal output Error appeared
- GC Alloc produced when adding items to MultiColumnListView with Auto Assign Binding
- Mouse and Pointer Events are called incorrectly in ScrollView with XRUIInputModule
- Scene view freezes when "NullReferenceException" is thrown in a .delayCall
- Memory leak occurs when repeatedly minimizing and maximizing the UI Builder window
Resolution Note:
Already addressed by a fix for a different issue. Fix will be available starting with version 1.0.15 of the logging package. The cause of the problem was improperly-sized buffers for strings consisting mostly of characters taking more than 2 bytes in UTF-8.