Commit 298d5ce0 authored by Eric Wong's avatar Eric Wong

avahi: malloc => xmalloc

git-svn-id: https://svn.musicpd.org/mpd/trunk@5262 09075e82-0dd4-0310-85a5-a0d7c8717e4f
parent 53427fb3
......@@ -25,6 +25,7 @@
#include "log.h"
#include "listen.h"
#include "ioops.h"
#include "utils.h"
/* The dns-sd service type qualifier to publish */
#define SERVICE_TYPE "_mpd._tcp"
......@@ -86,7 +87,7 @@ static AvahiTimeout* avahiTimeoutList;
static AvahiWatch* avahiWatchNew( const AvahiPoll *api, int fd, AvahiWatchEvent event, AvahiWatchCallback callback, void *userdata )
{
struct AvahiWatch* newWatch = malloc( sizeof(struct AvahiWatch) );
struct AvahiWatch* newWatch = xmalloc( sizeof(struct AvahiWatch) );
newWatch->fd = fd;
newWatch->requestedEvent = event;
......@@ -167,7 +168,7 @@ static void avahiTimeoutFree( AvahiTimeout *t )
static AvahiTimeout* avahiTimeoutNew( const AvahiPoll *api, const struct timeval *tv, AvahiTimeoutCallback callback, void *userdata )
{
struct AvahiTimeout* newTimeout = malloc( sizeof(struct AvahiTimeout) );
struct AvahiTimeout* newTimeout = xmalloc( sizeof(struct AvahiTimeout) );
newTimeout->callback = callback;
newTimeout->userdata = userdata;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment