mirror of
https://github.com/servalproject/serval-dna.git
synced 2025-01-29 15:43:56 +00:00
Fix compile warnings on Solaris (gcc 4.4)
This commit is contained in:
parent
00e1a59ca8
commit
c4b90a108b
@ -327,9 +327,9 @@ overlay_interface_read_any(struct sched_ent *alarm){
|
||||
/* We have a frame from this interface */
|
||||
if (debug&DEBUG_PACKETRX)
|
||||
DEBUG_packet_visualise("Read from real interface", packet,plen);
|
||||
if (debug&DEBUG_OVERLAYINTERFACES)
|
||||
if (debug&DEBUG_OVERLAYINTERFACES)
|
||||
DEBUGF("Received %d bytes from %s on interface %s (ANY)",plen,
|
||||
inet_ntoa(((struct sockaddr_in *)&src_addr)->sin_addr),
|
||||
inet_ntoa(src),
|
||||
interface->name);
|
||||
if (packetOk(interface,packet,plen,NULL,recvttl,&src_addr,addrlen,1)) {
|
||||
WHY("Malformed packet");
|
||||
@ -587,10 +587,12 @@ static void overlay_interface_poll(struct sched_ent *alarm)
|
||||
/* We have a frame from this interface */
|
||||
if (debug&DEBUG_PACKETRX)
|
||||
DEBUG_packet_visualise("Read from real interface", packet,plen);
|
||||
if (debug&DEBUG_OVERLAYINTERFACES)
|
||||
DEBUGF("Received %d bytes from %s on interface %s",plen,
|
||||
inet_ntoa(((struct sockaddr_in *)&src_addr)->sin_addr),
|
||||
if (debug&DEBUG_OVERLAYINTERFACES) {
|
||||
struct in_addr src = ((struct sockaddr_in *)&src_addr)->sin_addr; // avoid strict-alias warning on Solaris (gcc 4.4)
|
||||
DEBUGF("Received %d bytes from %s on interface %s",plen,
|
||||
inet_ntoa(src),
|
||||
interface->name);
|
||||
}
|
||||
if (packetOk(interface,packet,plen,NULL,recvttl,&src_addr,addrlen,1)) {
|
||||
WHY("Malformed packet");
|
||||
// Do we really want to attempt to parse it again?
|
||||
|
@ -352,8 +352,10 @@ sqlite3_stmt *_sqlite_prepare(struct __sourceloc __whence, sqlite_retry_state *r
|
||||
sqlite3_stmt *_sqlite_prepare_loglevel(struct __sourceloc __whence, int log_level, sqlite_retry_state *retry, strbuf stmt)
|
||||
{
|
||||
sqlite3_stmt *statement = NULL;
|
||||
if (strbuf_overrun(stmt))
|
||||
return WHYFNULL("SQL overrun: %s", strbuf_str(stmt));
|
||||
if (strbuf_overrun(stmt)) {
|
||||
WHYF("SQL overrun: %s", strbuf_str(stmt));
|
||||
return NULL;
|
||||
}
|
||||
if (!rhizome_db && rhizome_opendb() == -1)
|
||||
return NULL;
|
||||
while (1) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user