- Sort Score
- Result 10 results
- Languages All
Results 1 - 7 of 7 for NopCloser (0.09 sec)
-
cmd/test-utils_test.go
if err != nil { t.Fatal(failTestStr(anonTestStr, err.Error())) } // creating 2 read closer (to set as request body) from the body content. readerOne := io.NopCloser(bytes.NewBuffer(buf)) readerTwo := io.NopCloser(bytes.NewBuffer(buf)) anonReq.Body = readerOne // call the HTTP handler. apiRouter.ServeHTTP(rec, anonReq)
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Tue Oct 01 22:13:18 UTC 2024 - 77K bytes - Viewed (0) -
src/archive/zip/writer.go
w io.Writer count int64 } func (w *countWriter) Write(p []byte) (int, error) { n, err := w.w.Write(p) w.count += int64(n) return n, err } type nopCloser struct { io.Writer } func (w nopCloser) Close() error { return nil } type writeBuf []byte func (b *writeBuf) uint8(v uint8) { (*b)[0] = v *b = (*b)[1:] } func (b *writeBuf) uint16(v uint16) {
Registered: Tue Nov 05 11:13:11 UTC 2024 - Last Modified: Mon Sep 23 14:32:33 UTC 2024 - 19.4K bytes - Viewed (0) -
cmd/storage-rest-client.go
values.Set(storageRESTFilePath, path) values.Set(storageRESTLength, strconv.Itoa(int(size))) values.Set(storageRESTOrigVolume, origvolume) respBody, err := client.call(ctx, storageRESTMethodCreateFile, values, io.NopCloser(reader), size) defer xhttp.DrainBody(respBody) if err != nil { return err } _, err = waitForHTTPResponse(respBody) return toStorageErr(err) }
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Sun Oct 13 13:07:21 UTC 2024 - 30.2K bytes - Viewed (0) -
cmd/auth-handler.go
return ErrMalformedXML } // Populate payload to extract location constraint. r.Body = io.NopCloser(bytes.NewReader(payload)) region, s3Err = parseLocationConstraint(r) if s3Err != ErrNone { return s3Err } // Populate payload again to handle it in HTTP handler. r.Body = io.NopCloser(bytes.NewReader(payload)) } logger.GetReqInfo(ctx).Region = region return s3Err }
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Tue Sep 17 16:45:46 UTC 2024 - 26.1K bytes - Viewed (0) -
cmd/xl-storage-disk-id-check.go
ctx, done, err := p.TrackDiskHealth(ctx, storageMetricCreateFile, volume, path) if err != nil { return err } defer done(size, &err) return p.storage.CreateFile(ctx, origvolume, volume, path, size, io.NopCloser(reader)) } func (p *xlStorageDiskIDCheck) ReadFileStream(ctx context.Context, volume, path string, offset, length int64) (io.ReadCloser, error) {
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Sat Oct 26 09:56:26 UTC 2024 - 34.5K bytes - Viewed (0) -
cmd/admin-handlers-users_test.go
c.Fatalf("unexpected encryption err: %v", err) } req.ContentLength = int64(len(buf)) sum := sha256.Sum256(buf) req.Header.Set("X-Amz-Content-Sha256", hex.EncodeToString(sum[:])) req.Body = io.NopCloser(bytes.NewReader(buf)) req = signer.SignV4(*req, accessKey, secretKey, "", "") // 3.1 Execute the request. resp, err := s.TestSuiteCommon.client.Do(req) if err != nil {
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Sun Sep 22 00:33:43 UTC 2024 - 47.3K bytes - Viewed (0) -
cmd/erasure-server-pool.go
found++ var r io.ReadCloser if !si.Dir { r, err = disk.ReadFileStream(ctx, volume, si.Name, 0, si.Size) if err != nil { continue } } else { r = io.NopCloser(bytes.NewBuffer([]byte{})) } // Keep disk path instead of ID, to ensure that the downloaded zip file can be // easily automated with `minio server hostname{1...n}/disk{1...m}`.
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Sun Sep 29 22:40:36 UTC 2024 - 89.8K bytes - Viewed (0)