Commit f5ab2693 authored by Claes Sjofors's avatar Claes Sjofors

Compiled with gcc 6.3

parent 3c61f262
...@@ -57,6 +57,7 @@ ...@@ -57,6 +57,7 @@
#include "Epl.h" #include "Epl.h"
#include <errno.h> #include <errno.h>
#include <math.h> #include <math.h>
#include <unistd.h>
#include <rt_pwr_msg.h> #include <rt_pwr_msg.h>
/***************************************************************************/ /***************************************************************************/
......
...@@ -51,6 +51,7 @@ ...@@ -51,6 +51,7 @@
#include "Epl.h" #include "Epl.h"
#include <errno.h> #include <errno.h>
#include <math.h> #include <math.h>
#include <unistd.h>
#include <sys/socket.h> #include <sys/socket.h>
#include <netinet/in.h> #include <netinet/in.h>
#include <arpa/inet.h> #include <arpa/inet.h>
......
...@@ -785,6 +785,7 @@ static void* mb_connect(void* arg) ...@@ -785,6 +785,7 @@ static void* mb_connect(void* arg)
continue; continue;
} }
} }
return NULL;
} }
/*----------------------------------------------------------------------------*\ /*----------------------------------------------------------------------------*\
......
...@@ -96,7 +96,7 @@ int cnv_get_image(char* fname, cnv_tImImage* image, cnv_tPixmap* pixmap) ...@@ -96,7 +96,7 @@ int cnv_get_image(char* fname, cnv_tImImage* image, cnv_tPixmap* pixmap)
void cnv_free_image(cnv_tImImage image, cnv_tPixmap pixmap) void cnv_free_image(cnv_tImImage image, cnv_tPixmap pixmap)
{ {
#if defined PWRE_CONF_GTK #if defined PWRE_CONF_GTK
gdk_pixbuf_unref((GdkPixbuf*)image); g_object_unref((GdkPixbuf*)image);
#elif defined PWRE_IMLIB #elif defined PWRE_IMLIB
......
...@@ -929,6 +929,7 @@ static void* import_thread() ...@@ -929,6 +929,7 @@ static void* import_thread()
que_Put(NULL, &sp->lp->q_in, &sp->c.le, sp); que_Put(NULL, &sp->lp->q_in, &sp->c.le, sp);
sp = iseg_alloc(); sp = iseg_alloc();
} }
return NULL;
} }
static void ini_link_info(qdb_sLinkInfo* lp) static void ini_link_info(qdb_sLinkInfo* lp)
......
...@@ -1161,6 +1161,7 @@ static void* import_thread() ...@@ -1161,6 +1161,7 @@ static void* import_thread()
que_Put(NULL, &sp->lp->q_in, &sp->c.le, sp); que_Put(NULL, &sp->lp->q_in, &sp->c.le, sp);
sp = iseg_alloc(); sp = iseg_alloc();
} }
return NULL;
} }
static void ini_link_info(qdb_sLinkInfo* lp) static void ini_link_info(qdb_sLinkInfo* lp)
......
...@@ -312,4 +312,5 @@ static void* log_thread(void* arg) ...@@ -312,4 +312,5 @@ static void* log_thread(void* arg)
} }
} }
} }
return NULL;
} }
...@@ -1993,7 +1993,7 @@ void FlowDrawGtk::image_scale(float scale, flow_tImImage orig_im, ...@@ -1993,7 +1993,7 @@ void FlowDrawGtk::image_scale(float scale, flow_tImImage orig_im,
int current_height = int(scale * gdk_pixbuf_get_height((GdkPixbuf*)orig_im)); int current_height = int(scale * gdk_pixbuf_get_height((GdkPixbuf*)orig_im));
if (*im) if (*im)
gdk_pixbuf_unref((GdkPixbuf*)*im); g_object_unref((GdkPixbuf*)*im);
*im = gdk_pixbuf_scale_simple( *im = gdk_pixbuf_scale_simple(
(GdkPixbuf*)orig_im, current_width, current_height, GDK_INTERP_NEAREST); (GdkPixbuf*)orig_im, current_width, current_height, GDK_INTERP_NEAREST);
} }
...@@ -2034,7 +2034,7 @@ int FlowDrawGtk::image_load(const char* imagefile, float scale, float nav_scale, ...@@ -2034,7 +2034,7 @@ int FlowDrawGtk::image_load(const char* imagefile, float scale, float nav_scale,
return 0; return 0;
if (*im) if (*im)
gdk_pixbuf_unref((GdkPixbuf*)*im); g_object_unref((GdkPixbuf*)*im);
*orig_im = (flow_tImImage*)gdk_pixbuf_new_from_file(filename, 0); *orig_im = (flow_tImImage*)gdk_pixbuf_new_from_file(filename, 0);
int width = int(scale * gdk_pixbuf_get_width((GdkPixbuf*)*orig_im)); int width = int(scale * gdk_pixbuf_get_width((GdkPixbuf*)*orig_im));
......
...@@ -2806,7 +2806,7 @@ int GlowDrawGtk::print(char* filename, double x0, double x1, int end) ...@@ -2806,7 +2806,7 @@ int GlowDrawGtk::print(char* filename, double x0, double x1, int end)
ps->fp.flags(((ps->fp.flags() & ~ios_base::hex) & ~ios_base::uppercase) ps->fp.flags(((ps->fp.flags() & ~ios_base::hex) & ~ios_base::uppercase)
| ios_base::dec); | ios_base::dec);
} }
gdk_pixbuf_unref(image); g_object_unref(image);
return 1; return 1;
} }
...@@ -2900,7 +2900,7 @@ unsigned char* GlowDrawGtk::image_get_data(glow_tImImage image) ...@@ -2900,7 +2900,7 @@ unsigned char* GlowDrawGtk::image_get_data(glow_tImImage image)
void GlowDrawGtk::image_copy(glow_tImImage orig_image, glow_tImImage* image) void GlowDrawGtk::image_copy(glow_tImImage orig_image, glow_tImImage* image)
{ {
if (*image) if (*image)
gdk_pixbuf_unref((GdkPixbuf*)*image); g_object_unref((GdkPixbuf*)*image);
*(GdkPixbuf**)image = gdk_pixbuf_copy((GdkPixbuf*)orig_image); *(GdkPixbuf**)image = gdk_pixbuf_copy((GdkPixbuf*)orig_image);
} }
...@@ -2929,7 +2929,7 @@ void GlowDrawGtk::image_rotate( ...@@ -2929,7 +2929,7 @@ void GlowDrawGtk::image_rotate(
} }
GdkPixbuf* im GdkPixbuf* im
= gdk_pixbuf_rotate_simple((GdkPixbuf*)*image, (GdkPixbufRotation)grot); = gdk_pixbuf_rotate_simple((GdkPixbuf*)*image, (GdkPixbufRotation)grot);
gdk_pixbuf_unref((GdkPixbuf*)*image); g_object_unref((GdkPixbuf*)*image);
*image = (glow_tImImage)im; *image = (glow_tImImage)im;
#endif #endif
} }
...@@ -2940,7 +2940,7 @@ void GlowDrawGtk::image_flip_vertical(glow_tImImage* image) ...@@ -2940,7 +2940,7 @@ void GlowDrawGtk::image_flip_vertical(glow_tImImage* image)
return; return;
#else #else
GdkPixbuf* im = gdk_pixbuf_flip((GdkPixbuf*)*image, TRUE); GdkPixbuf* im = gdk_pixbuf_flip((GdkPixbuf*)*image, TRUE);
gdk_pixbuf_unref((GdkPixbuf*)*image); g_object_unref((GdkPixbuf*)*image);
*image = (glow_tImImage)im; *image = (glow_tImImage)im;
#endif #endif
} }
...@@ -2951,7 +2951,7 @@ void GlowDrawGtk::image_flip_horizontal(glow_tImImage* image) ...@@ -2951,7 +2951,7 @@ void GlowDrawGtk::image_flip_horizontal(glow_tImImage* image)
return; return;
#else #else
GdkPixbuf* im = gdk_pixbuf_flip((GdkPixbuf*)*image, FALSE); GdkPixbuf* im = gdk_pixbuf_flip((GdkPixbuf*)*image, FALSE);
gdk_pixbuf_unref((GdkPixbuf*)*image); g_object_unref((GdkPixbuf*)*image);
*image = (glow_tImImage)im; *image = (glow_tImImage)im;
#endif #endif
} }
...@@ -2976,7 +2976,7 @@ int GlowDrawGtk::image_scale(int width, int height, glow_tImImage orig_im, ...@@ -2976,7 +2976,7 @@ int GlowDrawGtk::image_scale(int width, int height, glow_tImImage orig_im,
GdkPixbuf* im_old = (GdkPixbuf*)*im; GdkPixbuf* im_old = (GdkPixbuf*)*im;
*im = gdk_pixbuf_scale_simple( *im = gdk_pixbuf_scale_simple(
(GdkPixbuf*)*im, width, height, GDK_INTERP_NEAREST); (GdkPixbuf*)*im, width, height, GDK_INTERP_NEAREST);
gdk_pixbuf_unref((GdkPixbuf*)im_old); g_object_unref((GdkPixbuf*)im_old);
} else { } else {
// Scale from orig_im // Scale from orig_im
...@@ -2985,7 +2985,7 @@ int GlowDrawGtk::image_scale(int width, int height, glow_tImImage orig_im, ...@@ -2985,7 +2985,7 @@ int GlowDrawGtk::image_scale(int width, int height, glow_tImImage orig_im,
RsvgHandle* handle; RsvgHandle* handle;
const char* imagefile; const char* imagefile;
gdk_pixbuf_unref((GdkPixbuf*)*im); g_object_unref((GdkPixbuf*)*im);
handle = (RsvgHandle*)*im_data; handle = (RsvgHandle*)*im_data;
imagefile = rsvg_handle_get_base_uri(handle); imagefile = rsvg_handle_get_base_uri(handle);
...@@ -2994,7 +2994,7 @@ int GlowDrawGtk::image_scale(int width, int height, glow_tImImage orig_im, ...@@ -2994,7 +2994,7 @@ int GlowDrawGtk::image_scale(int width, int height, glow_tImImage orig_im,
#endif #endif
{ {
if (*im) if (*im)
gdk_pixbuf_unref((GdkPixbuf*)*im); g_object_unref((GdkPixbuf*)*im);
*im = gdk_pixbuf_scale_simple( *im = gdk_pixbuf_scale_simple(
(GdkPixbuf*)orig_im, width, height, GDK_INTERP_NEAREST); (GdkPixbuf*)orig_im, width, height, GDK_INTERP_NEAREST);
} }
...@@ -3006,9 +3006,9 @@ int GlowDrawGtk::image_load(char* imagefile, glow_tImImage* orig_im, ...@@ -3006,9 +3006,9 @@ int GlowDrawGtk::image_load(char* imagefile, glow_tImImage* orig_im,
glow_tImImage* im, glow_tImData* im_data) glow_tImImage* im, glow_tImData* im_data)
{ {
if (im && *im) if (im && *im)
gdk_pixbuf_unref((GdkPixbuf*)*im); g_object_unref((GdkPixbuf*)*im);
if (*orig_im) if (*orig_im)
gdk_pixbuf_unref((GdkPixbuf*)*orig_im); g_object_unref((GdkPixbuf*)*orig_im);
#if defined PWRE_CONF_RSVG #if defined PWRE_CONF_RSVG
if (im_data && streq(strchr(imagefile, '.'), ".svg")) { if (im_data && streq(strchr(imagefile, '.'), ".svg")) {
RsvgHandle* handle; RsvgHandle* handle;
...@@ -3040,7 +3040,7 @@ int GlowDrawGtk::image_render(int width, int height, glow_tImImage orig_im, ...@@ -3040,7 +3040,7 @@ int GlowDrawGtk::image_render(int width, int height, glow_tImImage orig_im,
void GlowDrawGtk::image_free(glow_tImImage image) void GlowDrawGtk::image_free(glow_tImImage image)
{ {
gdk_pixbuf_unref((GdkPixbuf*)image); g_object_unref((GdkPixbuf*)image);
} }
void GlowDrawGtk::pixmap_free(glow_tPixmap pixmap) void GlowDrawGtk::pixmap_free(glow_tPixmap pixmap)
...@@ -3059,7 +3059,7 @@ void GlowDrawGtk::image_pixel_iter(glow_tImImage orig_image, ...@@ -3059,7 +3059,7 @@ void GlowDrawGtk::image_pixel_iter(glow_tImImage orig_image,
if (orig_image) { if (orig_image) {
if (image && *image != orig_image) if (image && *image != orig_image)
gdk_pixbuf_unref((GdkPixbuf*)*image); g_object_unref((GdkPixbuf*)*image);
*image = (glow_tImImage*)gdk_pixbuf_copy((GdkPixbuf*)orig_image); *image = (glow_tImImage*)gdk_pixbuf_copy((GdkPixbuf*)orig_image);
} else if (!*image) } else if (!*image)
return; return;
......
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