@Override
	public void flush() throws IOException {
		if (!isBuffered()) {
			return;
		}
		if (!(Kernel32.INSTANCE.FlushFileBuffers(handle.getNative()))) {
			throw new LastErrorException(Kernel32.INSTANCE.GetLastError());
		}
	}
Check whether this handle has buffered output

<p>
Windows can get touchy when trying to flush handles that are not actually buffered. If the
wrapped handle is not buffered, then this method must return false, otherwise, any attempt to
flush this stream will result in {@code ERROR_INVALID_HANDLE}.

@return
Ghidra/Framework/Pty/src/main/java/ghidra/pty/windows/HandleOutputStream.java