[PATCH] Do not flush BufFile for regular temp files

Started by Sergey Solovievabout 1 hour ago1 messageshackers
Jump to latest
#1Sergey Soloviev
sergey.soloviev@tantorlabs.ru

Hi, hackers!

I have noticed that when we call BufFileClose, then we flush any remaining data
to file unconditionally. But when we use regular temp files (BufFileCreateTemp),
then the file is deleted on close and that flush was useless.

There is simple patch checking whether we should flush data or not.

---
Sergey Soloviev

TantorLabs: https://tantorlabs.com

Attachments:

0001-Do-not-flush-BufFile-for-regular-temp-files.patchtext/x-patch; charset=UTF-8; name=0001-Do-not-flush-BufFile-for-regular-temp-files.patchDownload+3-3