working commit
This commit is contained in:
@@ -207,7 +207,7 @@ distcleancheck_listfiles = \
|
||||
ACLOCAL = ${SHELL} '/home/ziggi/Projects/stvpn/missing' aclocal-1.17
|
||||
AMTAR = $${TAR-tar}
|
||||
AM_DEFAULT_VERBOSITY = 1
|
||||
ASTYLE = /usr/bin/astyle
|
||||
ASTYLE = /bin/astyle
|
||||
AUTOCONF = ${SHELL} '/home/ziggi/Projects/stvpn/missing' autoconf
|
||||
AUTOHEADER = ${SHELL} '/home/ziggi/Projects/stvpn/missing' autoheader
|
||||
AUTOMAKE = ${SHELL} '/home/ziggi/Projects/stvpn/missing' automake-1.17
|
||||
@@ -229,7 +229,7 @@ ECHO_N = -n
|
||||
ECHO_T =
|
||||
ETAGS = etags
|
||||
EXEEXT =
|
||||
INSTALL = /usr/bin/install -c
|
||||
INSTALL = /bin/install -c
|
||||
INSTALL_DATA = ${INSTALL} -m 644
|
||||
INSTALL_PROGRAM = ${INSTALL}
|
||||
INSTALL_SCRIPT = ${INSTALL}
|
||||
@@ -239,7 +239,7 @@ LIBOBJS =
|
||||
LIBS = -Wl,--as-need -lprotobuf
|
||||
LTLIBOBJS =
|
||||
MAKEINFO = ${SHELL} '/home/ziggi/Projects/stvpn/missing' makeinfo
|
||||
MKDIR_P = /usr/bin/mkdir -p
|
||||
MKDIR_P = /bin/mkdir -p
|
||||
OBJEXT = o
|
||||
PACKAGE = helmet
|
||||
PACKAGE_BUGREPORT =
|
||||
@@ -249,7 +249,7 @@ PACKAGE_TARNAME = helmet
|
||||
PACKAGE_URL =
|
||||
PACKAGE_VERSION = 0.0.1
|
||||
PATH_SEPARATOR = :
|
||||
PROTOC = /usr/bin/protoc
|
||||
PROTOC = /bin/protoc
|
||||
RANLIB = ranlib
|
||||
SET_MAKE =
|
||||
SHELL = /bin/bash
|
||||
|
||||
@@ -11,19 +11,6 @@ extern "C" {
|
||||
|
||||
#include <resolver.hpp>
|
||||
|
||||
Address::Address(std::string iaddress, int ifamily) {
|
||||
address = iaddress;
|
||||
family = ifamily;
|
||||
}
|
||||
|
||||
int Address::GetFamily() {
|
||||
return family;
|
||||
}
|
||||
|
||||
std::string Address::GetAddress() {
|
||||
return address;
|
||||
}
|
||||
|
||||
std::expected<Address, std::string> Resolver::Resolve(std::string hostname) {
|
||||
struct sockaddr_in sa;
|
||||
if (inet_pton(AF_INET, hostname.data(), &(sa.sin_addr)) == 1) {
|
||||
|
||||
@@ -2,16 +2,6 @@
|
||||
#include <expected>
|
||||
#include <string>
|
||||
|
||||
class Address {
|
||||
private:
|
||||
int family;
|
||||
std::string address;
|
||||
public:
|
||||
Address(const std::string iaddress, const int ifamily);
|
||||
int GetFamily();
|
||||
std::string GetAddress();
|
||||
};
|
||||
|
||||
class Resolver {
|
||||
private:
|
||||
int family;
|
||||
|
||||
Reference in New Issue
Block a user