summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 675bb83)
raw | patch | inline | side by side (parent: 675bb83)
author | octo <octo> | |
Mon, 1 May 2006 12:55:18 +0000 (12:55 +0000) | ||
committer | octo <octo> | |
Mon, 1 May 2006 12:55:18 +0000 (12:55 +0000) |
src/Makefile.am | patch | blob | history | |
src/liboping.c | patch | blob | history | |
src/liboping.h | [deleted file] | patch | blob | history |
src/oping.c | patch | blob | history | |
src/oping.h | [new file with mode: 0644] | patch | blob |
diff --git a/src/Makefile.am b/src/Makefile.am
index 08e84455d86fb76ac70d3864864c7316379c99cf..a3a642fc5a17156ceb3ea106a1322f221632dd1b 100644 (file)
--- a/src/Makefile.am
+++ b/src/Makefile.am
AM_CFLAGS = -Wall -Werror
endif
-include_HEADERS = liboping.h
+include_HEADERS = oping.h
lib_LTLIBRARIES = liboping.la
#liboping_la_CFLAGS =
if BUILD_WITH_LIBSOCKET
liboping_la_LDFLAGS += -lsocket
endif
-liboping_la_SOURCES = liboping.h liboping.c
+liboping_la_SOURCES = oping.h liboping.c
bin_PROGRAMS = oping
diff --git a/src/liboping.c b/src/liboping.c
index f1b9cbac51c3f526c64e33123ee37d3ce245fe04..610c22de50d9e7c2dc1953d3c23563706a103bae 100644 (file)
--- a/src/liboping.c
+++ b/src/liboping.c
# include <netinet/icmp6.h>
#endif
-#include "liboping.h"
+#include "oping.h"
#if DEBUG
# define dprintf(...) printf ("%s[%4i]: %-20s: ", __FILE__, __LINE__, __FUNCTION__); printf (__VA_ARGS__)
diff --git a/src/liboping.h b/src/liboping.h
--- a/src/liboping.h
+++ /dev/null
@@ -1,86 +0,0 @@
-/**
- * Object oriented C module to send ICMP and ICMPv6 `echo's.
- * Copyright (C) 2006 Florian octo Forster <octo at verplant.org>
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2 of the License, or
- * (at your option) any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
- */
-
-#ifndef OCTO_PING_H
-#define OCTO_PING_H 1
-
-#if HAVE_CONFIG_H
-# include <config.h>
-#endif
-
-#if HAVE_STDLIB_H
-# include <stdlib.h>
-#endif
-#if HAVE_UNISTD_H
-# include <unistd.h>
-#endif
-#if HAVE_SYS_SOCKET_H
-# include <sys/socket.h>
-#endif
-
-/*
- * Type definitions
- */
-struct pinghost;
-typedef struct pinghost pinghost_t;
-
-typedef pinghost_t pingobj_iter_t;
-
-struct pingobj;
-typedef struct pingobj pingobj_t;
-
-#define PING_OPT_TIMEOUT 0x01
-#define PING_OPT_TTL 0x02
-#define PING_OPT_AF 0x04
-
-#define PING_DEF_TIMEOUT 1.0
-#define PING_DEF_TTL 255
-#define PING_DEF_AF AF_UNSPEC
-
-/*
- * Method definitions
- */
-pingobj_t *ping_construct (void);
-void ping_destroy (pingobj_t *obj);
-
-int ping_setopt (pingobj_t *obj, int option, void *value);
-
-int ping_send (pingobj_t *obj);
-
-int ping_host_add (pingobj_t *obj, const char *host);
-int ping_host_remove (pingobj_t *obj, const char *host);
-
-pingobj_iter_t *ping_iterator_get (pingobj_t *obj);
-pingobj_iter_t *ping_iterator_next (pingobj_iter_t *iter);
-
-#define PING_INFO_HOSTNAME 1
-#define PING_INFO_ADDRESS 2
-#define PING_INFO_FAMILY 3
-#define PING_INFO_LATENCY 4
-#define PING_INFO_SEQUENCE 5
-#define PING_INFO_IDENT 6
-int ping_iterator_get_info (pingobj_iter_t *iter, int info,
- void *buffer, size_t *buffer_len);
-
-const char *ping_get_error (pingobj_t *obj);
-
-void *ping_iterator_get_context (pingobj_iter_t *iter);
-void ping_iterator_set_context (pingobj_iter_t *iter, void *context);
-
-#endif /* OCTO_PING_H */
diff --git a/src/oping.c b/src/oping.c
index 07f0cec64d723fdd842ccd34ab4c1ed0454c41e3..cc115f27c4c07437595084773b65d9689eeca983 100644 (file)
--- a/src/oping.c
+++ b/src/oping.c
# include <signal.h>
#endif
-#include <liboping.h>
+#include "oping.h"
typedef struct ping_context
{
diff --git a/src/oping.h b/src/oping.h
--- /dev/null
+++ b/src/oping.h
@@ -0,0 +1,86 @@
+/**
+ * Object oriented C module to send ICMP and ICMPv6 `echo's.
+ * Copyright (C) 2006 Florian octo Forster <octo at verplant.org>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
+ */
+
+#ifndef OCTO_PING_H
+#define OCTO_PING_H 1
+
+#if HAVE_CONFIG_H
+# include <config.h>
+#endif
+
+#if HAVE_STDLIB_H
+# include <stdlib.h>
+#endif
+#if HAVE_UNISTD_H
+# include <unistd.h>
+#endif
+#if HAVE_SYS_SOCKET_H
+# include <sys/socket.h>
+#endif
+
+/*
+ * Type definitions
+ */
+struct pinghost;
+typedef struct pinghost pinghost_t;
+
+typedef pinghost_t pingobj_iter_t;
+
+struct pingobj;
+typedef struct pingobj pingobj_t;
+
+#define PING_OPT_TIMEOUT 0x01
+#define PING_OPT_TTL 0x02
+#define PING_OPT_AF 0x04
+
+#define PING_DEF_TIMEOUT 1.0
+#define PING_DEF_TTL 255
+#define PING_DEF_AF AF_UNSPEC
+
+/*
+ * Method definitions
+ */
+pingobj_t *ping_construct (void);
+void ping_destroy (pingobj_t *obj);
+
+int ping_setopt (pingobj_t *obj, int option, void *value);
+
+int ping_send (pingobj_t *obj);
+
+int ping_host_add (pingobj_t *obj, const char *host);
+int ping_host_remove (pingobj_t *obj, const char *host);
+
+pingobj_iter_t *ping_iterator_get (pingobj_t *obj);
+pingobj_iter_t *ping_iterator_next (pingobj_iter_t *iter);
+
+#define PING_INFO_HOSTNAME 1
+#define PING_INFO_ADDRESS 2
+#define PING_INFO_FAMILY 3
+#define PING_INFO_LATENCY 4
+#define PING_INFO_SEQUENCE 5
+#define PING_INFO_IDENT 6
+int ping_iterator_get_info (pingobj_iter_t *iter, int info,
+ void *buffer, size_t *buffer_len);
+
+const char *ping_get_error (pingobj_t *obj);
+
+void *ping_iterator_get_context (pingobj_iter_t *iter);
+void ping_iterator_set_context (pingobj_iter_t *iter, void *context);
+
+#endif /* OCTO_PING_H */