]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commit
crimson/osd: call pubsetbuf() before open() 68861/head
authorMatan Breizman <mbreizma@redhat.com>
Wed, 20 May 2026 08:22:22 +0000 (11:22 +0300)
committerMatan Breizman <mbreizma@redhat.com>
Wed, 20 May 2026 08:22:22 +0000 (11:22 +0300)
commit8297ead0e24df268efd25535d81533ee2ba8f73a
treedd3d87de293d26a8f4d32786879cac3feb165e53
parent1d09118286aff3737807dc7ef40fd55dbc863608
crimson/osd: call pubsetbuf() before open()

Move rdbuf()->pubsetbuf(nullptr, 0) before ofstream::open() since libstdc++
may ignore setbuf() once the filebuf is associated with a file.

```
setbuf() may only be called when the std::basic_filebuf is not associated with a file (has no effect otherwise)
```
https://en.cppreference.com/cpp/io/basic_filebuf/setbuf

Signed-off-by: Matan Breizman <mbreizma@redhat.com>
src/crimson/osd/main.cc