Skip to content

Commit

Permalink
Change header name
Browse files Browse the repository at this point in the history
  • Loading branch information
dtcooper committed Oct 23, 2024
1 parent 8949bb6 commit 30ba2ad
Show file tree
Hide file tree
Showing 5 changed files with 6 additions and 6 deletions.
2 changes: 1 addition & 1 deletion extras/test.sh
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ fi
run_test "preserve pre-existing preload (time)" "$EXPECTED" "$ACTUAL"

GIT_VER="$(git describe --tags --always --dirty=-modified 2>/dev/null || echo dev-nogit)"
DEBUG_STR="$(./fakehostname -v | fgrep -q '[debug enabled]' && echo ' [debug enabled]')"
DEBUG_STR="$(./fakehostname -v | grep -Fq '[debug enabled]' && echo ' [debug enabled]')"
EXPECTED="fakehostname version: ${GIT_VER}${DEBUG_STR}|libfakehostname version: ${GIT_VER}${DEBUG_STR} (./libfakehostname.$LIB_SUFFIX)"
ACTUAL="$(./fakehostname -v | strip_newlines)"
run_test "version check" "$EXPECTED" "$ACTUAL"
Expand Down
2 changes: 1 addition & 1 deletion extras/time_preload.c
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
#include <stdlib.h>
#include <time.h>

#include "../src/common.h"
#include "../src/fakehostname.h"


#ifdef ENABLE_DEBUG
Expand Down
2 changes: 1 addition & 1 deletion src/fakehostname.c
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
#endif
#include <unistd.h>

#include "common.h"
#include "fakehostname.h"

static char *custom_lib_path = NULL;
static char *new_hostname;
Expand Down
4 changes: 2 additions & 2 deletions src/common.h → src/fakehostname.h
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
#ifndef FAKEHOSTNAME_COMMON_H_
#define FAKEHOSTNAME_COMMON_H_
#ifndef FAKEHOSTNAME_H_
#define FAKEHOSTNAME_H_

// Apple or Linux configuration
#ifdef __APPLE__
Expand Down
2 changes: 1 addition & 1 deletion src/libfakehostname.c
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
#include <stdlib.h>
#include <sys/utsname.h>

#include "common.h"
#include "fakehostname.h"

static int (*__orig_gethostname)(char *name, size_t len) = NULL;
static int (*__orig_uname)(struct utsname *buf) = NULL;
Expand Down

0 comments on commit 30ba2ad

Please sign in to comment.