• Richard Musiol's avatar
    syscall: remove support for O_NONBLOCK and O_SYNC on js/wasm · 9e2a4f4d
    Richard Musiol authored
    This commit removes O_NONBLOCK on js/wasm. O_SYNC can't be
    removed, because it is referenced by the os package, so instead
    its use returns an error.
    
    On Windows, the options O_NONBLOCK and O_SYNC are not available
    when opening a file with Node.js. This caused the initialization
    of the syscall package to panic.
    
    The simplest solution is to not support these two options on js/wasm
    at all. Code written for js/wasm is supposed to be portable,
    so platform-specific options should not be used.
    
    Fixes #26524.
    
    Change-Id: I366aa3cdcfa59dfa9dc513368259f363ca090f00
    Reviewed-on: https://go-review.googlesource.com/126600Reviewed-by: 's avatarBrad Fitzpatrick <bradfitz@golang.org>
    Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org>
    TryBot-Result: Gobot Gobot <gobot@golang.org>
    9e2a4f4d
Name
Last commit
Last update
.github Loading commit data...
api Loading commit data...
doc Loading commit data...
lib/time Loading commit data...
misc Loading commit data...
src Loading commit data...
test Loading commit data...
.gitattributes Loading commit data...
.gitignore Loading commit data...
AUTHORS Loading commit data...
CONTRIBUTING.md Loading commit data...
CONTRIBUTORS Loading commit data...
LICENSE Loading commit data...
PATENTS Loading commit data...
README.md Loading commit data...
favicon.ico Loading commit data...
robots.txt Loading commit data...