#include <glib.h>
#include <gio/gio.h>
#include <stdio.h>
+#include <stdint.h>
#include <string.h>
#include <netinet/in.h>
#include <dns_sd.h>
return DNSSD_ERROR_OUT_OF_MEMORY; //LCOV_EXCL_LINE
}
- handler = (unsigned int)local_handle & 0xffffffff;
+ handler = (uintptr_t)local_handle & 0xffffffff;
*dnssd_service = handler;
local_handle->service_handler = handler;
local_handle->op_type = DNSSD_TYPE_REGISTER;
found = GET_FOUND_DATA_P(local_handle);
local_handle->op_type = DNSSD_TYPE_FOUND;
- local_handle->service_handler = (unsigned int)local_handle & 0xffffffff;
+ local_handle->service_handler = (uintptr_t)local_handle & 0xffffffff;
g_strlcpy(local_handle->domain, domain, sizeof(local_handle->domain));
local_handle->if_index = if_index;
local_handle->flags = flags;
return DNSSD_ERROR_OUT_OF_MEMORY; //LCOV_EXCL_LINE
}
- handler = (unsigned int)local_handle & 0xffffffff;
+ handler = (uintptr_t)local_handle & 0xffffffff;
*dnssd_service = handler;
local_handle->service_handler = handler;
local_handle->op_type = DNSSD_TYPE_BROWSE;
#include <stdio.h>
#include <unistd.h>
#include <stdlib.h>
+#include <stdint.h>
/*****************************************************************************
* System headers
found_service->usn = g_strdup(usn);
found_service->url = temp_url;
- found_service->service_handler = (unsigned int)found_service & 0xffffffff;
+ found_service->service_handler = (uintptr_t)found_service & 0xffffffff;
found_service->browser_id = browser->service_handler;
found_service->origin = SSDP_SERVICE_STATE_FOUND;
return SSDP_ERROR_OUT_OF_MEMORY; //LCOV_EXCL_LINE
}
- *ssdp_service = (unsigned int)service & 0xFFFFFFFF;
+ *ssdp_service = (uintptr_t)service & 0xFFFFFFFF;
SSDP_LOGD("Create handler for service [%u]", *ssdp_service);
service->service_handler = *ssdp_service;
service->origin = SSDP_SERVICE_STATE_NOT_REGISTERED;
}
/* Create browser handle */
- *ssdp_browser = (unsigned int)browser & 0xFFFFFFFF;
+ *ssdp_browser = (uintptr_t)browser & 0xFFFFFFFF;
SSDP_LOGD("Create handler for browser [%u]", *ssdp_browser);
browser->service_handler = *ssdp_browser;
g_hash_table_foreach(g_found_ssdp_services,
(GHFunc)__g_hash_remove_related_services,
- (gpointer)browser->service_handler);
+ (gpointer)(uintptr_t)browser->service_handler);
g_free(browser->target);
g_free(browser);