Skip to content

Commit

Permalink
Include <endianness.h> in files that need it
Browse files Browse the repository at this point in the history
Without this, operations on fixed values are miscompiled on big-endian
machines
  • Loading branch information
th-otto committed Mar 20, 2024
1 parent ffd4077 commit 61f7ed5
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 0 deletions.
1 change: 1 addition & 0 deletions common/fixed.h
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@
#define FIXED_H

#include <stdint.h>
#include "endianness.h"

/*
** This is a very simple fixed point class that functions like a regular integral type. However
Expand Down
1 change: 1 addition & 0 deletions tiberiandawn/defines.h
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@
#define DEFINES_H

#include "common/bitfields.h"
#include "common/endianness.h"

/**********************************************************************
** If defined, then the advanced balancing features will be enabled
Expand Down

0 comments on commit 61f7ed5

Please sign in to comment.