Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 2 of 2 for xlMetaV2TrimData (0.36 sec)

  1. cmd/xl-storage-meta-inline.go

    		*x = nil
    		return true
    	}
    
    	// Reserialize...
    	x.serialize(plSize, newKeys, newVals)
    	return true
    }
    
    // xlMetaV2TrimData will trim any data from the metadata without unmarshalling it.
    // If any error occurs the unmodified data is returned.
    func xlMetaV2TrimData(buf []byte) []byte {
    	metaBuf, min, maj, err := checkXL2V1(buf)
    	if err != nil {
    		return buf
    	}
    	if maj == 1 && min < 1 {
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Thu Apr 04 12:04:40 GMT 2024
    - 9.5K bytes
    - Viewed (0)
  2. cmd/xl-storage-format-v2_test.go

    	}
    	if !bytes.Equal(xl2.data.find(fi.VersionID), data2) {
    		t.Fatal("Find data returned", xl2.data.find(fi.DataDir))
    	}
    
    	// Test trimmed
    	xl2 = xlMetaV2{}
    	trimmed := xlMetaV2TrimData(serialized)
    	failOnErr(xl2.Load(trimmed))
    	if len(xl2.data) != 0 {
    		t.Fatal("data, was not trimmed, bytes left:", len(xl2.data))
    	}
    	// Corrupt metadata, last 5 bytes is the checksum, so go a bit further back.
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Fri Mar 08 17:50:48 GMT 2024
    - 36.4K bytes
    - Viewed (0)
Back to top