skalibs

Mirror/fork of https://skarnet.org/software/skalibs/
git clone https://ccx.te2000.cz/git/skalibs
Log | Files | Refs | README | LICENSE

uint32_unpack_big.c (220B)


      1 /* ISC license. */
      2 
      3 #include <stdint.h>
      4 #include <string.h>
      5 
      6 #include <skalibs/uint32.h>
      7 
      8 void uint32_unpack_big (char const *s, uint32_t *u)
      9 {
     10   uint32_t x ;
     11   memcpy(&x, s, sizeof(uint32_t)) ;
     12   *u = uint32_big(x) ;
     13 }