Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 15 for BeUint16 (0.4 sec)

  1. src/syscall/dirent.go

    	case 2:
    		return uint64(byteorder.BeUint16(b))
    	case 4:
    		return uint64(byteorder.BeUint32(b))
    	case 8:
    		return uint64(byteorder.BeUint64(b))
    	default:
    		panic("syscall: readInt with unsupported size")
    	}
    }
    
    func readIntLE(b []byte, size uintptr) uint64 {
    	switch size {
    	case 1:
    		return uint64(b[0])
    	case 2:
    		return uint64(byteorder.LeUint16(b))
    	case 4:
    		return uint64(byteorder.LeUint32(b))
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue May 14 20:13:24 UTC 2024
    - 2.4K bytes
    - Viewed (0)
  2. src/internal/byteorder/byteorder.go

    // license that can be found in the LICENSE file.
    
    // Package byteorder provides functions for decoding and encoding
    // little and big endian integer types from/to byte slices.
    package byteorder
    
    func LeUint16(b []byte) uint16 {
    	_ = b[1] // bounds check hint to compiler; see golang.org/issue/14808
    	return uint16(b[0]) | uint16(b[1])<<8
    }
    
    func LePutUint16(b []byte, v uint16) {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri May 10 20:31:29 UTC 2024
    - 3.5K bytes
    - Viewed (0)
  3. src/os/dir_unix.go

    	case 2:
    		return uint64(byteorder.BeUint16(b))
    	case 4:
    		return uint64(byteorder.BeUint32(b))
    	case 8:
    		return uint64(byteorder.BeUint64(b))
    	default:
    		panic("syscall: readInt with unsupported size")
    	}
    }
    
    func readIntLE(b []byte, size uintptr) uint64 {
    	switch size {
    	case 1:
    		return uint64(b[0])
    	case 2:
    		return uint64(byteorder.LeUint16(b))
    	case 4:
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue May 14 20:11:45 UTC 2024
    - 4.8K bytes
    - Viewed (0)
  4. src/crypto/tls/handshake_server.go

    	if err != nil {
    		c.sendAlert(alertHandshakeFailure)
    		return err
    	}
    	if skx != nil {
    		if len(skx.key) >= 3 && skx.key[0] == 3 /* named curve */ {
    			c.curveID = CurveID(byteorder.BeUint16(skx.key[1:]))
    		}
    		if _, err := hs.c.writeHandshakeRecord(skx, &hs.finishedHash); err != nil {
    			return err
    		}
    	}
    
    	var certReq *certificateRequestMsg
    	if c.config.ClientAuth >= RequestClientCert {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed May 22 21:30:50 UTC 2024
    - 27.6K bytes
    - Viewed (0)
  5. src/crypto/tls/handshake_client.go

    		if err != nil {
    			c.sendAlert(alertUnexpectedMessage)
    			return err
    		}
    		if len(skx.key) >= 3 && skx.key[0] == 3 /* named curve */ {
    			c.curveID = CurveID(byteorder.BeUint16(skx.key[1:]))
    		}
    
    		msg, err = c.readHandshake(&hs.finishedHash)
    		if err != nil {
    			return err
    		}
    	}
    
    	var chainToSend *Certificate
    	var certRequested bool
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu May 23 03:10:12 UTC 2024
    - 38.6K bytes
    - Viewed (0)
  6. src/crypto/tls/handshake_client_test.go

    	if len(test.extensions) > 0 {
    		var serverInfo bytes.Buffer
    		for _, ext := range test.extensions {
    			pem.Encode(&serverInfo, &pem.Block{
    				Type:  fmt.Sprintf("SERVERINFO FOR EXTENSION %d", byteorder.BeUint16(ext)),
    				Bytes: ext,
    			})
    		}
    		serverInfoPath := tempFile(serverInfo.String())
    		defer os.Remove(serverInfoPath)
    		command = append(command, "-serverinfo", serverInfoPath)
    	}
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu May 23 03:10:12 UTC 2024
    - 88.7K bytes
    - Viewed (0)
  7. src/cmd/internal/test2json/testdata/framefuzz.test

        inlining_test.go:102: not in expected set, but also inlinable: "Addr.isZero"
        inlining_test.go:102: not in expected set, but also inlinable: "bePutUint32"
        inlining_test.go:102: not in expected set, but also inlinable: "leUint16"
        inlining_test.go:102: not in expected set, but also inlinable: "Addr.string6"
        inlining_test.go:102: not in expected set, but also inlinable: "beUint64"
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed Oct 26 19:50:36 UTC 2022
    - 2.8K bytes
    - Viewed (0)
  8. src/cmd/internal/test2json/testdata/framefuzz.json

    {"Action":"output","Test":"TestInlining","Output":"    inlining_test.go:102: not in expected set, but also inlinable: \"leUint16\"\n"}
    {"Action":"output","Test":"TestInlining","Output":"    inlining_test.go:102: not in expected set, but also inlinable: \"Addr.string6\"\n"}
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed Nov 09 17:33:07 UTC 2022
    - 6.3K bytes
    - Viewed (0)
  9. src/syscall/dir_plan9.go

    }
    
    // gbit16 reads a 16-bit number in little-endian order from b and returns it with the remaining slice of b.
    //
    //go:nosplit
    func gbit16(b []byte) (uint16, []byte) {
    	return byteorder.LeUint16(b), b[2:]
    }
    
    // gbit32 reads a 32-bit number in little-endian order from b and returns it with the remaining slice of b.
    func gbit32(b []byte) (uint32, []byte) {
    	return byteorder.LeUint32(b), b[4:]
    }
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon May 20 19:32:38 UTC 2024
    - 5.2K bytes
    - Viewed (0)
  10. src/internal/poll/fd_wasip1.go

    		return 0, false
    	}
    	return readIntLE(b[off:], size), true
    }
    
    func readIntLE(b []byte, size uintptr) uint64 {
    	switch size {
    	case 1:
    		return uint64(b[0])
    	case 2:
    		return uint64(byteorder.LeUint16(b))
    	case 4:
    		return uint64(byteorder.LeUint32(b))
    	case 8:
    		return uint64(byteorder.LeUint64(b))
    	default:
    		panic("internal/poll: readInt with unsupported size")
    	}
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue May 14 20:14:02 UTC 2024
    - 6.7K bytes
    - Viewed (0)
Back to top