- Sort Score
- Result 10 results
- Languages All
Results 141 - 150 of 212 for newReader (0.07 sec)
-
docs/debugging/inspect/main.go
privateKey = b fmt.Println("Using private key from", *privKeyPath) } // Prompt for decryption key if no --key or --private-key are provided if len(privateKey) == 0 && !*stdin { reader := bufio.NewReader(os.Stdin) fmt.Print("Enter Decryption Key: ") text, _ := reader.ReadString('\n') // convert CRLF to LF *keyHex = strings.ReplaceAll(text, "\n", "") *keyHex = strings.TrimSpace(*keyHex) } }
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Fri May 31 14:49:23 UTC 2024 - 5.2K bytes - Viewed (0) -
internal/mountinfo/mountinfo_linux.go
if err != nil { return nil, err } defer file.Close() return parseMountFrom(file) } func parseMountFrom(file io.Reader) (mountInfos, error) { mounts := mountInfos{} scanner := bufio.NewReader(file) for { line, err := scanner.ReadString('\n') if err == io.EOF { break } fields := strings.Fields(line) if len(fields) != expectedNumFieldsPerLine { // ignore incorrect lines.
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Sun Jan 02 17:15:06 UTC 2022 - 4.7K bytes - Viewed (0) -
cmd/auth-handler.go
} // 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/main.go
fmt.Fprintln(banner, color.Blue("License:")+color.Bold(" GNU AGPLv3 - https://www.gnu.org/licenses/agpl-3.0.html")) fmt.Fprintln(banner, color.Blue("Copyright:")+color.Bold(" 2015-%s MinIO, Inc.", CopyrightYear)) return strings.NewReader(banner.String()) } func printMinIOVersion(c *cli.Context) { io.Copy(c.App.Writer, versionBanner(c)) } var debugNoExit = env.Get("_MINIO_DEBUG_NO_EXIT", "") != "" // Main main for minio server.
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Tue Jul 30 22:59:48 UTC 2024 - 6.5K bytes - Viewed (0) -
cmd/bitrot-streaming.go
if len(b.data) == 0 && b.tillOffset != streamOffset { b.rc, err = b.disk.ReadFileStream(context.TODO(), b.volume, b.filePath, streamOffset, b.tillOffset-streamOffset) } else { b.rc = io.NewSectionReader(bytes.NewReader(b.data), streamOffset, b.tillOffset-streamOffset) } if err != nil { return 0, err } } if offset != b.currOffset { // Can never happen unless there are programmer bugs
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Wed Aug 21 12:20:54 UTC 2024 - 6K bytes - Viewed (0) -
internal/ioutil/ioutil_test.go
func TestCopyAligned(t *testing.T) { f, err := os.CreateTemp("", "") if err != nil { t.Errorf("Error creating tmp file: %v", err) } defer f.Close() defer os.Remove(f.Name()) r := strings.NewReader("hello world") bufp := ODirectPoolSmall.Get().(*[]byte) defer ODirectPoolSmall.Put(bufp) written, err := CopyAligned(f, io.LimitReader(r, 5), *bufp, r.Size(), f) if !errors.Is(err, io.ErrUnexpectedEOF) {
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Wed May 22 23:07:14 UTC 2024 - 5.5K bytes - Viewed (0) -
internal/config/lambda/target/webhook.go
return nil, err } data, err := json.Marshal(eventData) if err != nil { return nil, err } req, err := http.NewRequest(http.MethodPost, target.args.Endpoint.String(), bytes.NewReader(data)) if err != nil { return nil, err } // Verify if the authToken already contains // <Key> <Token> like format, if this is // already present we can blindly use the
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Mon Jul 08 21:39:49 UTC 2024 - 6.7K bytes - Viewed (0) -
internal/bucket/replication/replication_test.go
expectedValidationErr: nil, }, } for i, tc := range testCases { t.Run(fmt.Sprintf("Test %d", i+1), func(t *testing.T) { cfg, err := ParseConfig(bytes.NewReader([]byte(tc.inputConfig))) if err != nil && tc.expectedParsingErr != nil && err.Error() != tc.expectedParsingErr.Error() { t.Fatalf("%d: Expected '%v' during parsing but got '%v'", i+1, tc.expectedParsingErr, err) }
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Thu Mar 28 17:44:56 UTC 2024 - 32.5K bytes - Viewed (0) -
internal/http/response-recorder.go
// Body - Return response body. func (lrw *ResponseRecorder) Body() []byte { if lrw.Header().Get("Content-Encoding") == "gzip" { if lrw.body.Len() > 1<<20 { return gzippedBody } r, err := gzip.NewReader(&lrw.body) if err != nil { return gzippedBody } defer r.Close() b, _ := io.ReadAll(io.LimitReader(r, 10<<20)) return b } // If there was an error response or body logging is enabled
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Tue Sep 24 17:13:00 UTC 2024 - 5.5K bytes - Viewed (0) -
cmd/erasure-healing-common.go
} // Always check data, if we got it. if (len(meta.Data) > 0 || meta.Size == 0) && len(meta.Parts) > 0 { checksumInfo := meta.Erasure.GetChecksumInfo(meta.Parts[0].Number) verifyErr := bitrotVerify(bytes.NewReader(meta.Data), int64(len(meta.Data)), meta.Erasure.ShardFileSize(meta.Size), checksumInfo.Algorithm, checksumInfo.Hash, meta.Erasure.ShardSize()) dataErrsByPart[0][i] = convPartErrToInt(verifyErr)
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Thu Oct 31 22:10:24 UTC 2024 - 12.7K bytes - Viewed (0)