# HG changeset patch
# User Laurent Bessard
# Date 1342743187 -7200
# Node ID 840d328560f852d5ab000fcaae67788e350a4f22
# Parent  05a267b1a362ca7ec91569361a83ef5791bad8d9
Fix bug with AXIS_REF allocation

diff -r 05a267b1a362 -r 840d328560f8 etherlab/etherlab.py
--- a/etherlab/etherlab.py	Mon Jun 25 20:06:17 2012 +0200
+++ b/etherlab/etherlab.py	Fri Jul 20 02:13:07 2012 +0200
@@ -982,7 +982,7 @@
                                             self.Controler.GetSizeOfType(entry_type)):
                                             raise ValueError, message
                                         else:
-                                            self.Controler.GetCTRoot().logger.write_warning(message + "\n")
+                                            self.Controler.GetCTRoot().logger.write_warning(_("Warning: ") + message + "\n")
                                     
                                     if (entry_infos["dir"] == "I" and pdo_type != "Inputs" or 
                                         entry_infos["dir"] == "Q" and pdo_type != "Outputs"):
diff -r 05a267b1a362 -r 840d328560f8 etherlab/plc_cia402node.c
--- a/etherlab/plc_cia402node.c	Mon Jun 25 20:06:17 2012 +0200
+++ b/etherlab/plc_cia402node.c	Fri Jul 20 02:13:07 2012 +0200
@@ -46,7 +46,8 @@
 int __init_%(location)s()
 {
 %(init_entry_variables)s
-	*__IW%(location)s_0 = __MK_Alloc_AXIS_REF(&(__CIA402Node_%(location)s.axis));
+	*__IW%(location)s_0 = __MK_Alloc_AXIS_REF();
+	__CIA402Node_%(location)s.axis = __MK_GetPublic_AXIS_REF(*__IW%(location)s_0);
 	return 0;
 }