//go:noinline - flush only called intermittently
434412
func (z *bufioEncWriter) flushErr() (err error) {
	n, err := z.w.Write(z.buf[:z.n])
	z.n -= n
	if z.n > 0 && err == nil {
		err = io.ErrShortWrite
	}
	if n > 0 && z.n > 0 {
		copy(z.buf, z.buf[n:z.n+n])
	}
	return err
}
1090660
func (w *responseWriter) Flush() {
	if flusher, ok := w.Flusher(); ok {
		flusher.Flush()
	}
}
1275402
func (b *BlockedEvals) Flush() {
	b.l.Lock()
	defer b.l.Unlock()

	// Reset the blocked eval tracker.
	b.stats.TotalEscaped = 0
	b.stats.TotalBlocked = 0
	b.stats.TotalQuotaLimit = 0
	b.captured = make(map[string]wrappedEval)
	b.escaped = make(map[string]wrappedEval)
	b.jobs = make(map[structs.NamespacedID]string)
	b.unblockIndexes = make(map[string]uint64)
	b.timetable = nil
	b.duplicates = nil
	b.capacityChangeCh = make(chan *capacityUpdate, unblockBuffer)
	b.stopCh = make(chan struct{})
	b.duplicateCh = make(chan struct{}, 1)
}
79342
func (c *RawBinaryClient) Flush(expiration uint32) Response {
	return c.genericOp(opFlush, expiration)
}
677423
func (c *EncodedConn) FlushTimeout(timeout time.Duration) (err error) {
	return c.Conn.FlushTimeout(timeout)
}
261227
func (w *http2responseWriter) Flush() {
	if flusher, ok := w.ResponseWriter.(http.Flusher); ok {
		flusher.Flush()
	}
}
957770
func (c *syncClient) Flushall() (err Error) {
	_, err = c.conn.ServiceRequest(&FLUSHALL, [][]byte{})
	return
}
408899
func Flush() error {
	update_size_maybe()
	prepare_diff_messages()
	for _, diff := range diffbuf {
		r := small_rect{
			left:   0,
			top:    diff.pos,
			right:  term_size.x - 1,
			bottom: diff.pos + diff.lines - 1,
		}
		write_console_output(out, diff.chars, r)
	}
	if !is_cursor_hidden(cursor_x, cursor_y) {
		move_cursor(cursor_x, cursor_y)
	}
	return nil
}
688199
func (p *BulkProcessor) Flush() error {
	p.statsMu.Lock()
	p.stats.Flushed++
	p.statsMu.Unlock()

	for _, w := range p.workers {
		w.flushC <- struct{}{}
		<-w.flushAckC // wait for completion
	}
	return nil
}
216502
func (s *routeStats) Flush() {
	s.mu.Lock()

	s.flushTimer = nil
	addWG := s.addWG
	s.addWG = nil
	m := s.m
	s.m = nil

	s.mu.Unlock()

	if m == nil {
		return
	}

	addWG.Wait()
	err := s.send(m)
	if err != nil {
		logger.Printf("routeStats.send failed: %s", err)
	}
}
269821
func (fp *Failpoint) flush(dst io.Writer) error {
	if len(fp.code) == 0 {
		return fp.flushSingle(dst)
	}
	return fp.flushMulti(dst)
}
1359548
func (wal *baseWAL) OnStop() {
	wal.flushTicker.Stop()
	wal.FlushAndSync()
	wal.group.Stop()
	wal.group.Close()
}
91742
func (s *TCP) Flush() error {
	defer func() {
		s.frames = s.frames[:0]
	}()
	c, err := net.DialTimeout("tcp", s.address, time.Second)
	if err != nil {
		return err
	}
	enc, err := fs.NewEncoder(c, &fs.EncoderOptions{
		ContentType:   []byte("protobuf:dnstap.Dnstap"),
		Bidirectional: true,
	})
	if err != nil {
		return err
	}
	for _, frame := range s.frames {
		if _, err = enc.Write(frame); err != nil {
			return err
		}
	}
	return enc.Flush()
}
295664
func (w *ConditionalWrite) Flush() string {
	combined := strings.Join(w.Queued, "")
	if len(combined) == 0 {
		return ""
	}

	w.Queued = nil
	if len(combined) == 1 {
		return "buf.WriteByte('" + combined + "')" + "\n"
	}
	return "buf.WriteString(`" + combined + "`)" + "\n"
}
176469
func (rw *responseWriter) Flush() {
	if fw, ok := rw.w.(http.Flusher); ok {
		fw.Flush()
	}
}
149220
func (e *BoundaryWriter) Flush() error {
	if e.buffered == "" {
		return nil
	}
	if n, err := e.Target.Write([]byte(e.buffered)); err != nil || n != len(e.buffered) {
		return err
	}
	e.buffered = ""
	return nil
}
1109162
func (l *BytesBufferLogger) Flush() {
	l.mux.Lock()
	defer l.mux.Unlock()
	l.buf.Reset()
}