summaryrefslogtreecommitdiff
path: root/src/libstddjb/uint16_pack_big.c
blob: c24f78fc330edf040c0c98ede1eb82b4b864fc12 (plain)
1
2
3
4
5
6
7
8
9
10
11
/* ISC license. */

#include <stdint.h>
#include <string.h>
#include <skalibs/uint16.h>

void uint16_pack_big (char *s, uint16_t u)
{
  u = uint16_big(u) ;
  memcpy(s, &u, sizeof(uint16_t)) ;
}