summaryrefslogtreecommitdiffstats
path: root/src/extension
diff options
context:
space:
mode:
Diffstat (limited to 'src/extension')
-rw-r--r--src/extension/internal/gnome.cpp2
-rw-r--r--src/extension/internal/pdf.cpp5
-rw-r--r--src/extension/internal/ps.cpp5
-rw-r--r--src/extension/internal/win32.cpp5
4 files changed, 10 insertions, 7 deletions
diff --git a/src/extension/internal/gnome.cpp b/src/extension/internal/gnome.cpp
index 6c6563e7e..4bdec5f98 100644
--- a/src/extension/internal/gnome.cpp
+++ b/src/extension/internal/gnome.cpp
@@ -423,7 +423,7 @@ nr_artpath_to_art_bpath(NArtBpath const *s)
i = 0;
while (s[i].code != NR_END) i += 1;
- ArtBpath* d = nr_new (ArtBpath, i + 1);
+ ArtBpath* d = g_new (ArtBpath, i + 1);
i = 0;
while (s[i].code != NR_END) {
diff --git a/src/extension/internal/pdf.cpp b/src/extension/internal/pdf.cpp
index ed98c4a29..938f570b7 100644
--- a/src/extension/internal/pdf.cpp
+++ b/src/extension/internal/pdf.cpp
@@ -31,6 +31,7 @@
#include <signal.h>
#include <errno.h>
+#include <glib/gmem.h>
#include <libnr/n-art-bpath.h>
#include <libnr/nr-point-matrix-ops.h>
@@ -405,7 +406,7 @@ PrintPDF::finish(Inkscape::Extension::Print *mod)
nr_arena_item_set_transform(mod->root, &affine);
- guchar *const px = nr_new(guchar, 4 * width * 64);
+ guchar *const px = g_new(guchar, 4 * width * 64);
for (int y = 0; y < height; y += 64) {
/* Set area of interest. */
@@ -439,7 +440,7 @@ PrintPDF::finish(Inkscape::Extension::Print *mod)
print_image(_stream, px, bbox.x1 - bbox.x0, bbox.y1 - bbox.y0, 4 * width, &imgt);
}
- nr_free(px);
+ g_free(px);
}
pdf_file->end_page(page_stream);
diff --git a/src/extension/internal/ps.cpp b/src/extension/internal/ps.cpp
index c814637c6..a72b88461 100644
--- a/src/extension/internal/ps.cpp
+++ b/src/extension/internal/ps.cpp
@@ -32,6 +32,7 @@
#include <libnr/n-art-bpath.h>
+#include <glib/gmem.h>
#include <gtk/gtkstock.h>
#include <gtk/gtkvbox.h>
#include <gtk/gtkframe.h>
@@ -451,7 +452,7 @@ PrintPS::finish(Inkscape::Extension::Print *mod)
nr_arena_item_set_transform(mod->root, &affine);
- guchar *const px = nr_new(guchar, 4 * width * 64);
+ guchar *const px = g_new(guchar, 4 * width * 64);
for (int y = 0; y < height; y += 64) {
/* Set area of interest. */
@@ -485,7 +486,7 @@ PrintPS::finish(Inkscape::Extension::Print *mod)
print_image(_stream, px, bbox.x1 - bbox.x0, bbox.y1 - bbox.y0, 4 * width, &imgt);
}
- nr_free(px);
+ g_free(px);
}
fprintf(_stream, "showpage\n");
diff --git a/src/extension/internal/win32.cpp b/src/extension/internal/win32.cpp
index 335a77a09..51dbd3a00 100644
--- a/src/extension/internal/win32.cpp
+++ b/src/extension/internal/win32.cpp
@@ -13,6 +13,7 @@
# include "config.h"
#endif
+#include <glib/gmem.h>
#include <libnr/nr-macros.h>
#include <libnr/nr-matrix.h>
@@ -312,7 +313,7 @@ PrintWin32::finish (Inkscape::Extension::Print *mod)
width = x1 - x0;
height = y1 - y0;
- px = nr_new (unsigned char, 4 * 64 * width);
+ px = g_new (unsigned char, 4 * 64 * width);
sheight = 64;
/* Printing goes here */
@@ -368,7 +369,7 @@ PrintWin32::finish (Inkscape::Extension::Print *mod)
nr_pixblock_release (&pb);
}
- nr_free (px);
+ g_free (px);
res = EndPage (_hDC);
res = EndDoc (_hDC);