Coder Social home page Coder Social logo

Comments (2)

TianlongLiang avatar TianlongLiang commented on August 25, 2024

Similar to #3565, O_DSYNC is not part of the file status flags that can be modified using fcntl. You can only set its value when first set it with open

from wasm-micro-runtime.

TianlongLiang avatar TianlongLiang commented on August 25, 2024

Refer to the manual of syscall open and fcntl:

In open

       In addition, zero or more file creation flags and file status
       flags can be bitwise ORed in flags.  The file creation flags are
       O_CLOEXEC, O_CREAT, O_DIRECTORY, O_EXCL, O_NOCTTY, O_NOFOLLOW,
       O_TMPFILE, and O_TRUNC.  The file status flags are all of the
       remaining flags listed below.  The distinction between these two
       groups of flags is that the file creation flags affect the
       semantics of the open operation itself, while the file status
       flags affect the semantics of subsequent I/O operations.  **The
       file status flags can be retrieved and (in some cases) modified**;
       see [fcntl(2)](https://man7.org/linux/man-pages/man2/fcntl.2.html) for details.

In fcntl

       F_SETFL (int)
              Set the file status flags to the value specified by arg.
              File access mode (O_RDONLY, O_WRONLY, O_RDWR) and file
              creation flags (i.e., O_CREAT, O_EXCL, O_NOCTTY, O_TRUNC)
              in arg are ignored.  On Linux, this operation can change
              only the O_APPEND, O_ASYNC, O_DIRECT, O_NOATIME, and
              O_NONBLOCK flags.  It is not possible to change the
              O_DSYNC and O_SYNC flags; see BUGS, below.

from wasm-micro-runtime.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.