MCPcopy Index your code
hub / github.com/coder/coder / Bytes

Method Bytes

codersdk/toolsdk/bash.go:373–381  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

371}
372
373func (sw *syncWriter) Bytes() []byte {
374 sw.mu.Lock()
375 defer sw.mu.Unlock()
376 // Return a copy to prevent race conditions with the underlying buffer
377 b := sw.w.Bytes()
378 result := make([]byte, len(b))
379 copy(result, b)
380 return result
381}

Callers 15

debugCollectProfileMethod · 0.45
TestPostFilesFunction · 0.45
TestParseUUID_InvalidFunction · 0.45
TestRequestIDFunction · 0.45
dispatchMethod · 0.45
TestSMTPFunction · 0.45
ServerSentEventSenderFunction · 0.45
FlushMethod · 0.45
PGDumpFunction · 0.45

Calls 2

LockMethod · 0.45
UnlockMethod · 0.45

Tested by 15

TestPostFilesFunction · 0.36
TestParseUUID_InvalidFunction · 0.36
TestRequestIDFunction · 0.36
TestSMTPFunction · 0.36
FlushMethod · 0.36
buildMultipartResponseFunction · 0.36
parseLogLinesFunction · 0.36
TestLimitWriterFunction · 0.36
TestStatusWriterFunction · 0.36
TestExpTaskListFunction · 0.36