Skip to content

Conversation

@Rapsssito
Copy link
Collaborator

@Rapsssito Rapsssito commented Feb 2, 2020

Before, if you called createSocket('udp4') and bind() close together on production while running on a fast JS engine like Hermes, you would get the following error: "no client found with id X".

This was caused because createSocket('udp4') was running asynchronously and had not push the new socket to the SparseArray when the bind() method was called.

@Rapsssito Rapsssito requested a review from mvayngrib February 2, 2020 12:30
@Rapsssito Rapsssito changed the title fix(Android): createSocket is now a blocking method on Android fix(Android): createSocket is now a blocking method Feb 2, 2020
yonghongren added a commit to yonghongren/react-native-udp that referenced this pull request Apr 20, 2020
Picked up from tradle#108:

       Before, if you called createSocket('udp4') and bind() close together on production while running on a fast JS engine like Hermes, you would get the following error: "no client found with id X".

        This was caused because createSocket('udp4') was running asynchronously and had not push the new socket to the SparseArray when the bind() method was called.
@eliaslecomte
Copy link
Contributor

@mvayngrib What do you think of this?

@Rapsssito Rapsssito merged commit 6796a7f into tradle:master May 2, 2020
@Rapsssito Rapsssito deleted the createSocketfix branch May 2, 2020 18:20
github-actions bot pushed a commit that referenced this pull request Aug 15, 2020
# [2.6.0](v2.5.0...v2.6.0) (2020-08-15)

### Bug Fixes

* **Android:** createSocket is now a blocking method ([#108](#108)) ([6796a7f](6796a7f))
* RN 62.0 compatibility ([#112](#112)) ([7d202de](7d202de))

### Features

* Add Typescript types and the option to enable debugging ([#114](#114)) ([11e6e49](11e6e49))

### Performance Improvements

* Dependency reduction & JS update ([#105](#105)) ([aac2bfa](aac2bfa))
github-actions bot pushed a commit that referenced this pull request Aug 15, 2020
# [3.2.0](v3.1.0...v3.2.0) (2020-08-15)

### Bug Fixes

* **Android:** createSocket is now a blocking method ([#108](#108)) ([6796a7f](6796a7f))

### Features

* Add Typescript types and the option to enable debugging ([#114](#114)) ([11e6e49](11e6e49))

### Performance Improvements

* Dependency reduction & JS update ([#105](#105)) ([aac2bfa](aac2bfa))
@github-actions
Copy link

🎉 This PR is included in version 3.2.0 🎉

The release is available on:

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants