From 1e166c13aaabe8d2aad1d604c77020a14dc577cd Mon Sep 17 00:00:00 2001 From: open-license-manager <rillf@maildrop.cc> Date: 周二, 16 9月 2014 06:22:21 +0800 Subject: [PATCH] refactorings --- src/library/os/linux/os-linux.cpp | 6 ++++-- 1 files changed, 4 insertions(+), 2 deletions(-) diff --git a/src/library/os/linux/os-linux.cpp b/src/library/os/linux/os-linux.cpp index ed3427b..1f65304 100644 --- a/src/library/os/linux/os-linux.cpp +++ b/src/library/os/linux/os-linux.cpp @@ -1,4 +1,6 @@ +#ifndef _GNU_SOURCE #define _GNU_SOURCE /* To get defns of NI_MAXSERV and NI_MAXHOST */ +#endif #include <arpa/inet.h> #include <sys/socket.h> #include <netdb.h> @@ -21,7 +23,7 @@ #include <sys/ioctl.h> #include <sys/stat.h> #include "../os-cpp.h" -#include "../../base/public-key.h" +#include "public-key.h" #include <openssl/evp.h> #include <openssl/bio.h> @@ -57,7 +59,7 @@ const char* signatureB64) { EVP_MD_CTX *mdctx = NULL; - char *pubKey = PUBLIC_KEY; + const char *pubKey = PUBLIC_KEY; BIO* bio = BIO_new_mem_buf((void*) (pubKey), strlen(pubKey)); RSA *rsa = PEM_read_bio_RSAPublicKey(bio, NULL, NULL, NULL); -- Gitblit v1.9.1