Skip to content

Commit

Permalink
Add missing header guards
Browse files Browse the repository at this point in the history
  • Loading branch information
negativeExponent committed Sep 24, 2020
1 parent 7d6348a commit 6a1bb59
Show file tree
Hide file tree
Showing 7 changed files with 35 additions and 4 deletions.
5 changes: 5 additions & 0 deletions deps/zlib/gzguts.h
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@
* For conditions of distribution and use, see copyright notice in zlib.h
*/

#ifndef GZGUTS_H
#define GZGUTS_H

#ifdef _LARGEFILE64_SOURCE
# ifndef _LARGEFILE_SOURCE
# define _LARGEFILE_SOURCE 1
Expand Down Expand Up @@ -191,3 +194,5 @@ char ZLIB_INTERNAL *gz_strwinerror OF((DWORD error));
unsigned ZLIB_INTERNAL gz_intmax OF((void));
# define GT_OFF(x) (sizeof(int) == sizeof(z_off64_t) && (x) > gz_intmax())
#endif

#endif /* GZGUTS_H */
5 changes: 5 additions & 0 deletions deps/zlib/inffast.h
Original file line number Diff line number Diff line change
Expand Up @@ -8,4 +8,9 @@
subject to change. Applications should only use zlib.h.
*/

#ifndef INFFAST_H
#define INFFAST_H

void ZLIB_INTERNAL inflate_fast OF((z_streamp strm, unsigned start));

#endif /* INFFAST_H */
6 changes: 6 additions & 0 deletions deps/zlib/inflate.h
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,10 @@
trailer decoding by inflate(). NO_GZIP would be used to avoid linking in
the crc code when it is not needed. For shared libraries, gzip decoding
should be left enabled. */

#ifndef INFLATE_H
#define INFLATE_H

#ifndef NO_GZIP
# define GUNZIP
#endif
Expand Down Expand Up @@ -120,3 +124,5 @@ struct inflate_state {
int back; /* bits back of last unprocessed length/lit */
unsigned was; /* initial length of match */
};

#endif /* INFLATE_H */
5 changes: 5 additions & 0 deletions deps/zlib/inftrees.h
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,9 @@
subject to change. Applications should only use zlib.h.
*/

#ifndef INFTREES_H
#define INFTREES_H

/* Structure for decoding tables. Each entry provides either the
information needed to do the operation requested by the code that
indexed that table entry, or it provides a pointer to another
Expand Down Expand Up @@ -60,3 +63,5 @@ typedef enum {
int ZLIB_INTERNAL inflate_table OF((codetype type, unsigned short FAR *lens,
unsigned codes, code FAR * FAR *table,
unsigned FAR *bits, unsigned short FAR *work));

#endif /* INFTREES_H */
5 changes: 5 additions & 0 deletions mednafen/cdrom/CDAccess_CCD.h
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,9 @@
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*/

#ifndef CDACCESS_CCD_H
#define CDACCESS_CCD_H

#include "../FileStream.h"
#include "../MemoryStream.h"
#include "CDAccess.h"
Expand Down Expand Up @@ -46,3 +49,5 @@ class CDAccess_CCD : public CDAccess
size_t img_numsectors;
TOC tocd;
};

#endif /* CDACCESS_CCD_H */
5 changes: 5 additions & 0 deletions mednafen/cdrom/CDAccess_CHD.h
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,9 @@
** 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
*/

#ifndef CDACCESS_CHD_H
#define CDACCESS_CHD_H

#include <mednafen/FileStream.h>
#include <mednafen/MemoryStream.h>

Expand Down Expand Up @@ -98,3 +101,5 @@ class CDAccess_CHD : public CDAccess
/* last hunknum read */
int oldhunk;
};

#endif /* CDACCESS_CHD_H */
8 changes: 4 additions & 4 deletions mednafen/include/blip/Blip_Buffer.h
Original file line number Diff line number Diff line change
@@ -1,6 +1,10 @@
// Band-limited sound synthesis buffer
// Various changes and hacks for use in Mednafen.

// Blip_Buffer 0.4.1
#ifndef BLIP_BUFFER_H
#define BLIP_BUFFER_H

#ifdef __GNUC__
#define blip_inline inline __attribute__((always_inline))
#else
Expand All @@ -10,10 +14,6 @@
#include <limits.h>
#include <stdint.h>

// Blip_Buffer 0.4.1
#ifndef BLIP_BUFFER_H
#define BLIP_BUFFER_H

// Internal
typedef int32_t blip_long;
typedef uint32_t blip_ulong;
Expand Down

0 comments on commit 6a1bb59

Please sign in to comment.