[clutter] matrix: Fix the init_with_matrix() implementation
- From: Emmanuele Bassi <ebassi src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [clutter] matrix: Fix the init_with_matrix() implementation
- Date: Sun, 19 Aug 2012 17:31:07 +0000 (UTC)
commit f7dd2d374661003e0855b5d33d270381895b1cbf
Author: Emmanuele Bassi <ebassi gnome org>
Date: Thu Aug 16 16:13:38 2012 +0100
matrix: Fix the init_with_matrix() implementation
As usual, I swapped the memcpy() arguments around.
clutter/clutter-base-types.c | 8 +++-----
clutter/clutter-types.h | 12 ++++++------
2 files changed, 9 insertions(+), 11 deletions(-)
---
diff --git a/clutter/clutter-base-types.c b/clutter/clutter-base-types.c
index 7c4794f..91fbd95 100644
--- a/clutter/clutter-base-types.c
+++ b/clutter/clutter-base-types.c
@@ -1376,10 +1376,8 @@ clutter_matrix_init_from_array (ClutterMatrix *matrix,
* Since: 1.12
*/
ClutterMatrix *
-clutter_matrix_init_from_matrix (ClutterMatrix *a,
- ClutterMatrix *b)
+clutter_matrix_init_from_matrix (ClutterMatrix *a,
+ const ClutterMatrix *b)
{
- memcpy (b, a, sizeof (ClutterMatrix));
-
- return a;
+ return memcpy (a, b, sizeof (ClutterMatrix));
}
diff --git a/clutter/clutter-types.h b/clutter/clutter-types.h
index 3020568..d5e4662 100644
--- a/clutter/clutter-types.h
+++ b/clutter/clutter-types.h
@@ -697,12 +697,12 @@ void clutter_interval_register_progress_func (GType value_type,
GType clutter_matrix_get_type (void) G_GNUC_CONST;
ClutterMatrix * clutter_matrix_alloc (void);
-ClutterMatrix * clutter_matrix_init_identity (ClutterMatrix *matrix);
-ClutterMatrix * clutter_matrix_init_from_array (ClutterMatrix *matrix,
- const float values[16]);
-ClutterMatrix * clutter_matrix_init_from_matrix (ClutterMatrix *a,
- ClutterMatrix *b);
-void clutter_matrix_free (ClutterMatrix *matrix);
+ClutterMatrix * clutter_matrix_init_identity (ClutterMatrix *matrix);
+ClutterMatrix * clutter_matrix_init_from_array (ClutterMatrix *matrix,
+ const float values[16]);
+ClutterMatrix * clutter_matrix_init_from_matrix (ClutterMatrix *a,
+ const ClutterMatrix *b);
+void clutter_matrix_free (ClutterMatrix *matrix);
G_END_DECLS
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]