File: ntp_endian.h

package info (click to toggle)
ntpsec 1.2.3%2Bdfsg1-8
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 10,960 kB
  • sloc: ansic: 62,004; python: 32,017; sh: 1,553; yacc: 1,293; makefile: 190; javascript: 138
file content (18 lines) | stat: -rw-r--r-- 513 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
/* ntp_endian.h - BSD-style big-endian encoding/decoding functions
 *
 * Copyright the NTPsec project contributors
 * SPDX-License-Identifier: BSD-2-Clause
 *
 * These are portable reimplementations of what BSD provides
 * in <sys/endian.h>.
 */
#ifndef GUARD_NTP_ENDIAN_H
#define GUARD_NTP_ENDIAN_H

#include <stdint.h>

uint16_t ntp_be16dec(const void *buf) __attribute__((pure));
uint32_t ntp_be32dec(const void *buf) __attribute__((pure));
uint64_t ntp_be64dec(const void *buf) __attribute__((pure));

#endif