Skip to content

Commit

Permalink
Revert to 4-Nov to fix chrome compatibility
Browse files Browse the repository at this point in the history
  • Loading branch information
intika committed Mar 2, 2019
1 parent 0a56d70 commit 2232f02
Show file tree
Hide file tree
Showing 24 changed files with 206 additions and 733 deletions.
4 changes: 1 addition & 3 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,7 @@ sysconfdir=$(prefix)/etc

SRCS = $(sort $(wildcard src/*.c))
OBJS = $(SRCS:.c=.o)
LOBJS = src/core.o src/common.o src/libproxybound.o src/shm.o \
src/allocator_thread.o src/ip_type.o src/stringdump.o \
src/hostentdb.o src/hash.o
LOBJS = src/core.o src/common.o src/libproxybound.o

CFLAGS += -Wall -O0 -g -std=c99 -D_GNU_SOURCE -pipe
LDFLAGS = -shared -fPIC -Wl,--no-as-needed -ldl -lpthread
Expand Down
289 changes: 0 additions & 289 deletions src/allocator_thread.c

This file was deleted.

15 changes: 0 additions & 15 deletions src/allocator_thread.h

This file was deleted.

24 changes: 0 additions & 24 deletions src/common.c
Original file line number Diff line number Diff line change
Expand Up @@ -3,30 +3,6 @@
#include <unistd.h>
#include <stdio.h>

// stolen from libulz (C) rofl0r
void pc_stringfromipv4(unsigned char *ip_buf_4_bytes, char *outbuf_16_bytes) {
unsigned char *p;
char *o = outbuf_16_bytes;
unsigned char n;
for(p = ip_buf_4_bytes; p < ip_buf_4_bytes + 4; p++) {
n = *p;
if(*p >= 100) {
if(*p >= 200)
*(o++) = '2';
else
*(o++) = '1';
n %= 100;
}
if(*p >= 10) {
*(o++) = (n / 10) + '0';
n %= 10;
}
*(o++) = n + '0';
*(o++) = '.';
}
o[-1] = 0;
}

static int check_path(char *path) {
if(!path)
return 0;
Expand Down
9 changes: 2 additions & 7 deletions src/common.h
Original file line number Diff line number Diff line change
@@ -1,18 +1,13 @@
#ifndef COMMON_H
#define COMMON_H

#define PROXYBOUND_CONF_FILE_ENV_VAR "PROXYBOUND_CONF_FILE"
#define PROXYBOUND_QUIET_MODE_ENV_VAR "PROXYBOUND_QUIET_MODE"
#define PROXYBOUND_CONF_FILE "proxybound.conf"
#define LOG_PREFIX "[proxybound] "
#define LOG_PREFIX "[Proxybound] "
#ifndef SYSCONFDIR
#define SYSCONFDIR "/etc"
#endif

#include <stddef.h>

char *get_config_path(char* default_path, char* pbuf, size_t bufsize);
void pc_stringfromipv4(unsigned char *ip_buf_4_bytes, char *outbuf_16_bytes);

//RcB: DEP "common.c"
#endif
//RcB: DEP "common.c"
Loading

0 comments on commit 2232f02

Please sign in to comment.