question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

NetworkClientFactory initialization causes exception on some platforms

See original GitHub issue

Describe the bug On some platforms, Initializing Socket.Buffer to 0 causes the following exception: RtspClientSharp.Rtsp.RtspClientException: Connection error ---> System.ArgumentException: Value does not fall within the expected range.

Commenting out the referenced line seems to fix the issue. Currently, this is line 15 of NetworkClientFactory.cs.

This may be related to the implementation of System.Net.Sockets.Socket in the .NET equivalent in the Apple ecosystem. This issue does not occur on Windows.

To Reproduce This occurred in a project which integrates RtspClientSharp in Unity. It ran without issue on Windows, but failed on Mac and in a build for tvOS.

  1. Place the code into a Unity project
  2. Wrap the code in a MonoBehavior
  3. Press play and run the MonoBehavior

(Please note the above steps are already completed in this test repo I made for this issue)

When the initialization runs an exception will be thrown and should be caught in the Debug log.

Expected behavior Successfully initialize the socket and continue with program execution

  • Device: MacBook Air, build also attempted for Apple TV
  • OS: macOS Mojave 10.14.5, tvOS 12.3
  • Browser N/A
  • RtspClientSharp v1.2.8
  • Unity 2018, Unity 2019

Additional context Unity on Mac uses Mono, and states it is “.NET 4.5 equivalent” - I am unsure if this is related.

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Comments:9 (4 by maintainers)

github_iconTop GitHub Comments

1reaction
BogdanovKirillcommented, Jul 16, 2019

Hello,

Thank you for report. I should add some checks for platform before modifying send buffer size.

0reactions
tfsJoecommented, Jul 17, 2019

This was ok for me!

Read more comments on GitHub >

github_iconTop Results From Across the Web

Exception during context initialization - java
SpringApplication : Application startup failed org.springframework.beans.factory.BeanCreationException: Error creating bean with name ...
Read more >
EmbeddedKafka startup fails after updated to spring-kafka ...
After Updated to spring-boot 2.6 and spring-kafka 2.8.0 EmbeddedKafka fails to startup on Windows (see Stacktrace below). It works fine on Linux ...
Read more >
SCM fails to start: Error getting predicates
Hello, today CDH5.1.3 has suddenly stopped working. Health monitoring no longer works, but I can acces Cloudera - 21815.
Read more >
AM (All versions) fails to connect to DS using a secured ...
The purpose of this article is to provide assistance if AM fails to connect to DS using a secured connection (SSL/TLS enabled).
Read more >
Java client Timed out waiting for a node assignment
Hi, I have installed Confluent Platform on a Centos7 VM. It works fine from within the VM's guest OS. Now I want to...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found