From 23a9f7a79845e9a6633c3bdf06748b3885488682 Mon Sep 17 00:00:00 2001
From: Ingo Ruhnke <grumbel@gmx.de>
Date: Wed, 15 Dec 2010 02:34:31 +0100
Subject: [PATCH] Fixed incorrect order of calls

---
 src/uinput_cfg.cpp | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/uinput_cfg.cpp b/src/uinput_cfg.cpp
index 02c602b..3e29dd9 100644
--- a/src/uinput_cfg.cpp
+++ b/src/uinput_cfg.cpp
@@ -59,8 +59,8 @@ uInputCfg::get_axis_map(int n)
 void
 uInputCfg::add_input_mapping()
 {
-  current_input_map = map.size()-1;
   map.push_back(InputMapping());
+  current_input_map = map.size()-1;
   set_defaults();
 }