1
0
mirror of git://sourceware.org/git/lvm2.git synced 2024-12-21 13:34:40 +03:00

libdaemon: header cleanup

Ensure  daemon-io.h is used as a generic header included
with configure defines before other headers.
(In future all lvm2 libraries should settle on a single lib.h header)
Rename couple defines to better match header file names.
This commit is contained in:
Zdenek Kabelac 2014-04-17 10:40:35 +02:00
parent e552824dc0
commit b7741f0a83
8 changed files with 14 additions and 19 deletions

View File

@ -12,15 +12,14 @@
* Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*/
#include "daemon-io.h"
#include "dm-logging.h"
#include <errno.h>
#include <stdio.h>
#include <string.h>
#include <unistd.h>
#include "dm-logging.h"
#include "config-util.h"
#include "libdevmapper.h"
int buffer_append_vf(struct buffer *buf, va_list ap)
{
char *append;

View File

@ -15,7 +15,6 @@
#ifndef _LVM_DAEMON_CONFIG_UTIL_H
#define _LVM_DAEMON_CONFIG_UTIL_H
#include "configure.h"
#include "libdevmapper.h"
#include <stdarg.h>
@ -64,4 +63,4 @@ struct dm_config_node *config_make_nodes(struct dm_config_tree *cft,
struct dm_config_node *pre_sib,
...);
#endif /* _LVM_DAEMON_SHARED_H */
#endif /* _LVM_DAEMON_CONFIG_UTIL_H */

View File

@ -13,7 +13,6 @@
*/
#include "daemon-io.h"
#include "config-util.h"
#include "daemon-client.h"
#include "dm-logging.h"
@ -208,4 +207,3 @@ void daemon_request_destroy(daemon_request r) {
dm_config_destroy(r.cft);
buffer_destroy(&r.buffer);
}

View File

@ -12,8 +12,8 @@
* Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*/
#ifndef _LVM_DAEMON_COMMON_CLIENT_H
#define _LVM_DAEMON_COMMON_CLIENT_H
#ifndef _LVM_DAEMON_CLIENT_H
#define _LVM_DAEMON_CLIENT_H
#include "libdevmapper.h"
#include "config-util.h"

View File

@ -12,14 +12,14 @@
* Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*/
#include "daemon-io.h"
#include "libdevmapper.h"
#include <errno.h>
#include <stdio.h>
#include <string.h>
#include <unistd.h>
#include "daemon-io.h"
#include "libdevmapper.h"
/*
* Read a single message from a (socket) filedescriptor. Messages are delimited
* by blank lines. This call will block until all of a message is received. The

View File

@ -16,16 +16,16 @@
#define _LVM_DAEMON_IO_H
#include "configure.h"
#include "config-util.h"
#include "libdevmapper.h"
#define _REENTRANT
#define _GNU_SOURCE
#define _FILE_OFFSET_BITS 64
#include "config-util.h"
/* TODO function names */
int buffer_read(int fd, struct buffer *buffer);
int buffer_write(int fd, const struct buffer *buffer);
#endif /* _LVM_DAEMON_SHARED_H */
#endif /* _LVM_DAEMON_IO_H */

View File

@ -11,7 +11,6 @@
*/
#include "daemon-io.h"
#include "config-util.h"
#include "daemon-server.h"
#include "daemon-log.h"

View File

@ -12,8 +12,8 @@
* Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*/
#ifndef _LVM_DAEMON_COMMON_SERVER_H
#define _LVM_DAEMON_COMMON_SERVER_H
#ifndef _LVM_DAEMON_SERVER_H
#define _LVM_DAEMON_SERVER_H
#include "daemon-client.h"