Changeset 2d1994c9 in rtems


Ignore:
Timestamp:
Jun 24, 2010, 7:57:58 PM (10 years ago)
Author:
Joel Sherrill <joel.sherrill@…>
Branches:
4.11, master
Children:
8bef4cc
Parents:
287febb5
Message:

2010-06-24 Bharath Suri <bharath.s.jois@…>

PR 1542/filesystem
PR 1585/filesystem

  • libfs/src/pipe/fifo.c: pipe_control_t was not deallocated if fifo_open() was attempted with (O_WRONLY|O_NONBLOCK). Mutex was locked too many times on this path and we needed an unlock.
Location:
cpukit
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • cpukit/ChangeLog

    r287febb5 r2d1994c9  
     12010-06-24      Bharath Suri <bharath.s.jois@gmail.com>
     2
     3        PR 1542/filesystem
     4        PR 1585/filesystem
     5        * libfs/src/pipe/fifo.c: pipe_control_t was not deallocated if
     6        fifo_open() was attempted with (O_WRONLY|O_NONBLOCK).
     7        Mutex was locked too many times on this path and we needed an unlock.
     8
    192010-06-24      Joel Sherrill <joel.sherrilL@OARcorp.com>
    210
  • cpukit/libfs/src/pipe/fifo.c

    r287febb5 r2d1994c9  
    104104  if (! pipe->Buffer)
    105105    goto err_buf;
     106
     107  err = -ENOMEM;
    106108
    107109  if (rtems_barrier_create(
     
    343345
    344346    case LIBIO_FLAGS_WRITE:
     347      pipe->writerCounter ++;
     348
     349      if (pipe->Writers ++ == 0)
     350        PIPE_WAKEUPREADERS(pipe);
     351
    345352      if (pipe->Readers == 0 && LIBIO_NODELAY(iop)) {
     353        PIPE_UNLOCK(pipe);
    346354        err = -ENXIO;
    347355        goto out_error;
    348356      }
    349 
    350       pipe->writerCounter ++;
    351       if (pipe->Writers ++ == 0)
    352         PIPE_WAKEUPREADERS(pipe);
    353357
    354358      if (pipe->Readers == 0) {
Note: See TracChangeset for help on using the changeset viewer.