diff --git a/src/arm_control.cpp b/src/arm_control.cpp
index 70bbe693c56ebaa25db04b900edf8577432ef8af..94b388371dac514b286515521fce65066fe63f78 100644
--- a/src/arm_control.cpp
+++ b/src/arm_control.cpp
@@ -718,7 +718,7 @@ void CArmControl::load_poses(const std::string &filename)
   {
     // try to open the specified file
     try{
-      std::auto_ptr<arm_motions_t> motions(arm_motions(filename.c_str(), xml_schema::flags::dont_validate));
+      std::unique_ptr<arm_motions_t> motions(arm_motions(filename.c_str(), xml_schema::flags::dont_validate));
       for(iterator=motions->arm_motion().begin(),i=0;iterator!=motions->arm_motion().end();iterator++,i++)
       {
         if(iterator->button_name()=="triangle")