Skip to content

Commit

Permalink
remove stupid macro
Browse files Browse the repository at this point in the history
  • Loading branch information
sunflsks committed Aug 30, 2021
1 parent 0608695 commit 7fb65d7
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions get_new_argv.c
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,6 @@
#include <unistd.h>
#include "libiosexec.h"

#define STRINGS_ARE_NOT_EQUAL(x, y, len) strncmp(x, y, len)

static inline int has_non_printable_char(char* str, size_t n) {
for (int i = 0; i < n; i++) {
if (!isprint(str[i])) {
Expand Down Expand Up @@ -55,7 +53,7 @@ char** get_new_argv(const char* path, char* const argv[]) {

bool hasBang = 1;

if (STRINGS_ARE_NOT_EQUAL("#!", first_line, 2)) {
if (strncmp("#!", first_line, 2)) {
hasBang = 0;
}

Expand Down

0 comments on commit 7fb65d7

Please sign in to comment.