Unity-Technologies / Unity-Technologies/com.unity.webrtc

[BUG]: String conversion error when turn native webrtc log

Open
#968 0 comments 0 reactions 1 assignee View on GitHub

@karasusan is already working on this.

Since Sep 1, 2023.

bug
Dominant language
Assembly
Stars
852
Forks
238
PR merge metrics
No merged PRs in 30d

Description

Package version

3.0.0-pre.7

Environment
* OS: Windows10
* Unity version:: Unity 2021.3
Steps To Reproduce

Turn on native log via:
WebRTC.Initialize(true, true);

After running some time, it got error in logs:
001:977: Port[5932c8d0:1:1:0:local:Net[Intel(R):10.59.60.x/32:Ethernet:id=3]]: Gathered candidate: Cand[:252203621:1:udp:2122129151:10.59.60.x:65027:local::0:ItnH:EDLIe6ck1PlXm3RfCJ6RoNb1:3:0:0]
001:977: Port[5932c8d0:1:1:0:local:Net[Intel(R):10.59.60.x/32:Ethernet:id=3]]: Port ready.
001:977: Port[5932c8d0:1:1:0:local:Net[Intel(R):10.59.60.x/32:Ethernet:id=3]]: Starting STUN host lookup for stun.l.google.com:19302
001:977: Port[5932c8d0:1:1:0:local:Net[Intel(R):10.59.60.x/32:Ethernet:id=3]]: Starting STUN host lookup for stun1.l.google.com:19302
001:977: Setting RTCP Transport on 0 transport 0
001:977: Setting RTP Transport on 0 transport 26abf440
001:977: Set ICE ufrag: BqeI pwd: JlPffUjlx/dvXcGElw6upIar on transport 0
001:977: DtlsTransport[0|1|__]: DTLS setup complete.
001:977: Session: 9107051533049479575 Old state: have-remote-offer New state: stable
001:977: Port[528b3f90:0:1:0:local:Net[宽带连接:2409:871e:8f00❌x❌x:x/128:Unknown:id=2]]: StunPort: stun host lookup received error 0
ExecutionEngineException: String conversion error: Illegal byte sequence encounted in the input.
at (wrapper managed-to-native) System.Object.__icall_wrapper_ves_icall_string_new_wrapper(intptr)
at (wrapper native-to-managed) Unity.WebRTC.WebRTC.DebugLog(intptr)
UnityEngine.DebugLogHandler:Internal_LogException(Exception, Object)
UnityEngine.DebugLogHandler:LogException(Exception, Object)
UnityEngine.Logger:LogException(Exception, Object)
UnityEngine.Debug:LogException(Exception)
UnityEngine.<>c:b__0_0(Object, UnhandledExceptionEventArgs)
System.Object:__icall_wrapper_ves_icall_string_new_wrapper(IntPtr)

Current Behavior

No response

Expected Behavior

No response

Anything else?

No response

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.