📄 windows_extra.c
字号:
/* $Id: windows_extra.c,v 1.2 2000/11/17 22:51:37 jm Exp $ * Low level functions for not included features for Windows (cygwin32) * * Dynamic hierarchial IP tunnel * Copyright (C) 2000, Dynamics group * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License version 2 as * published by the Free Software Foundation. See README and COPYING for * more details. */#include "config.h"#ifdef DYN_TARGET_WINDOWS#include <stdio.h>#include <netinet/in.h>/* FIX: for some reason inet_aton() was not available in cygwin's libraries, so * it is define here; this may need to be removed if the function is added to * the libraries.. */int inet_aton(const char *cp, struct in_addr *inp){ int a1, a2, a3, a4; a1 = a2 = a3 = a4 = 0; if (sscanf(cp, "%d.%d.%d.%d", &a1, &a2, &a3, &a4) != 4) return 0; inp->s_addr = htonl((a1 << 24) | (a2 << 16) | (a3 << 8) | a4); return 1;}#endif /* DYN_TARGET_WINDOWS */
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -