Skip to content

Commit

Permalink
Merge pull request #24 from longbai/ipv6_opt
Browse files Browse the repository at this point in the history
fixed cocoapod release
  • Loading branch information
longbai committed May 27, 2016
2 parents 8e39dea + 57134b7 commit e341d28
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 6 deletions.
2 changes: 1 addition & 1 deletion HappyDNS.podspec
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Pod::Spec.new do |s|
s.name = 'HappyDNS'
s.version = '0.3.2'
s.version = '0.3.3'
s.summary = 'DNS library for iOS and Mac'
s.homepage = 'https://github.com/qiniu/happy-dns-objc'
s.social_media_url = 'http://weibo.com/qiniutek'
Expand Down
6 changes: 4 additions & 2 deletions HappyDNS/QNResolvUtil.h
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,10 @@
#ifndef QNResolv_h
#define QNResolv_h

BOOL isV6(NSString *address);
#include <resolv.h>

int setup_dns_server(res_state res, NSString *dns_server);
extern BOOL isV6(NSString *address);

extern int setup_dns_server(res_state res, NSString *dns_server);

#endif /* QNResolv_h */
4 changes: 2 additions & 2 deletions HappyDNS/Util/QNIP.h
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,8 @@

#import <Foundation/Foundation.h>

int qn_localIp(char *buf, int buf_size);
void qn_nat64(char *buf, int buf_size, uint32_t ipv4addr);
extern int qn_localIp(char *buf, int buf_size);
extern void qn_nat64(char *buf, int buf_size, uint32_t ipv4addr);

@interface QNIP : NSObject

Expand Down
2 changes: 1 addition & 1 deletion HappyDNS/Util/QNIP.m
Original file line number Diff line number Diff line change
Expand Up @@ -191,7 +191,7 @@ + (NSString *)nat64:(NSString *)ip {
struct in_addr s = {0};
inet_pton(AF_INET, ip.UTF8String, (void *)&s);
char buf[64] = {0};
qn_nat64(buf, sizeof(buf), s.s_addr);
qn_nat64(buf, sizeof(buf), (uint32_t)s.s_addr);
return [NSString stringWithUTF8String:buf];
}

Expand Down

0 comments on commit e341d28

Please sign in to comment.