summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorKris De Gussem <kris.degussem@gmail.com>2013-10-07 19:25:41 +0000
committerKris <Kris.De.Gussem@hotmail.com>2013-10-07 19:25:41 +0000
commit1a36f75406b76a837ac8d79719a7c23f8d693fed (patch)
tree47c10381fb58bc37a35a0972587527b0515bd836 /src
parentcppcheck: initialisation (diff)
downloadinkscape-1a36f75406b76a837ac8d79719a7c23f8d693fed.tar.gz
inkscape-1a36f75406b76a837ac8d79719a7c23f8d693fed.zip
cppcheck
(bzr r12669)
Diffstat (limited to 'src')
-rw-r--r--src/libcola/gradient_projection.h2
-rw-r--r--src/libcroco/cr-num.c4
-rw-r--r--src/libdepixelize/kopftracer2011.cpp3
-rw-r--r--src/sp-filter.cpp2
4 files changed, 4 insertions, 7 deletions
diff --git a/src/libcola/gradient_projection.h b/src/libcola/gradient_projection.h
index 66fc37aba..8cf45586c 100644
--- a/src/libcola/gradient_projection.h
+++ b/src/libcola/gradient_projection.h
@@ -225,7 +225,7 @@ public:
delete [] g;
delete [] d;
delete [] old_place;
- for(Constraints::iterator i(gcs.begin()); i!=gcs.end(); i++) {
+ for(Constraints::iterator i(gcs.begin()); i!=gcs.end(); ++i) {
delete *i;
}
gcs.clear();
diff --git a/src/libcroco/cr-num.c b/src/libcroco/cr-num.c
index c714894d6..062784c84 100644
--- a/src/libcroco/cr-num.c
+++ b/src/libcroco/cr-num.c
@@ -91,15 +91,13 @@ cr_num_new_with_val (gdouble a_val, enum CRNumType a_type)
guchar *
cr_num_to_string (CRNum * a_this)
{
- gdouble test_val = 0.0;
-
guchar *tmp_char1 = NULL,
*tmp_char2 = NULL,
*result = NULL;
g_return_val_if_fail (a_this, NULL);
- test_val = a_this->val - (glong) a_this->val;
+ gdouble test_val = a_this->val - (glong) a_this->val;
if (!test_val) {
tmp_char1 = (guchar *)g_strdup_printf ("%ld", (glong) a_this->val);
diff --git a/src/libdepixelize/kopftracer2011.cpp b/src/libdepixelize/kopftracer2011.cpp
index 95f91fdcb..ab31d05c3 100644
--- a/src/libdepixelize/kopftracer2011.cpp
+++ b/src/libdepixelize/kopftracer2011.cpp
@@ -336,8 +336,7 @@ inline int Heuristics::curves(const PixelGraph &graph,
{
// There are only two values that won't be zero'ed
// and one of them has the same value of prev
- guintptr aux = guintptr(to_ptr(it));
- aux = (it->adj.top
+ guintptr aux = (it->adj.top
* guintptr(to_ptr(graph.nodeTop(it))))
+ (it->adj.topright
* guintptr(to_ptr(graph.nodeTopRight(it))))
diff --git a/src/sp-filter.cpp b/src/sp-filter.cpp
index 1a5c65be9..9d45c92fc 100644
--- a/src/sp-filter.cpp
+++ b/src/sp-filter.cpp
@@ -114,7 +114,7 @@ void SPFilter::release() {
this->href = NULL;
}
- for (map<gchar *, int, ltstr>::const_iterator i = this->_image_name->begin() ; i != this->_image_name->end() ; i++) {
+ for (map<gchar *, int, ltstr>::const_iterator i = this->_image_name->begin() ; i != this->_image_name->end() ; ++i) {
g_free(i->first);
}