Ouyang Yadong

Results 66 comments of Ouyang Yadong

We need pass `--cargo-cwd` to both: https://github.com/napi-rs/napi-rs/blob/548f358fdbaeba43be4a91aaec3b411a404ffb61/cli/src/build.ts#L218~#L221 and: https://github.com/napi-rs/napi-rs/blob/548f358fdbaeba43be4a91aaec3b411a404ffb61/cli/src/build.ts#L358 for building in correct directory. But other code might not work as expected, e.g. it still generates .node files in `process.cwd()`....

I tried to add a `into_ref()` like the one for `JsBuffer` but I still got an InvalidArg error when calling `JsFunction`. Need some more investigation.

Finally, I think I understand why I still got `InvalidArg` after wrapping a `JsFunction` in `Ref`. It's because `napi_value` (that is a raw pointer) referenced by `napi_create_reference` could become invalid...

@Brooooooklyn I suggest adding a new api to get js values from `Ref`, and adding `into_ref()` for both `JsFunction` and `JsObject`, consider that node-addon-api have `FunctionReference` and `ObjectReference`. How do...

> I suggest adding a new api to get js values from Ref, and adding into_ref() for both JsFunction and JsObject Just noticed that we could create a reference by...

server也是默认net模块创建的tcp server,要看你的目标是“多快”,因为server要等到所有的连接都关闭后才会触发回调

如果端口被占用,很可能是因为运行环境不支持udp6,但我现在也没办法确定

我会从下个版本里面把这条提示信息从error编程warning

如果不是端口已经被占用的话,应该是因为不支持ipv6导致的,但应该不影响使用,因为udp转发基本没什么用。(印象中当时开发时我基本上找不到支持udp转发的软件)

Shadowsocks fits personally using very well but it's hard to extends a common username/password authetication. I would like to consider a better implementation of this so that I would delay...