getgateway.h 477 Bytes
//
//  getgateway.h
//
//  Created by cairui01 on 18/11/9.
//  Copyright (c) 2018年 baidu. All rights reserved.
//
#ifndef __GETGATEWAY_H__
#define __GETGATEWAY_H__

#include <stdint.h>
struct in_addr;
struct in6_addr;

#ifdef __cplusplus
extern "C" {
#endif

/* getdefaultgateway() :
 * return value :
 *    0 : success
 *   -1 : failure    */
int getdefaultgateway(struct in_addr * addr);
int getdefaultgateway6(struct in6_addr * addr);

#ifdef __cplusplus
}
#endif

#endif