Browse Source

Clarify macro variables for USE_INTERNAL_EDIT.

Signed-off-by: Andreas Mohr <and@gmx.li>
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
Andreas Mohr 9 years ago
parent
commit
c2060a420a
3 changed files with 8 additions and 0 deletions
  1. 4 0
      src/main.c
  2. 2 0
      src/setup.c
  3. 2 0
      src/setup.h

+ 4 - 0
src/main.c

@@ -351,7 +351,9 @@ main (int argc, char *argv[])
 
     load_keymap_defs (!mc_args__nokeymap);
 
+#ifdef USE_INTERNAL_EDIT
     macros_list = g_array_new (TRUE, FALSE, sizeof (macros_t));
+#endif /* USE_INTERNAL_EDIT */
 
     tty_init_colors (mc_global.tty.disable_colors, mc_args__force_colors);
 
@@ -450,6 +452,7 @@ main (int argc, char *argv[])
 
     done_key ();
 
+#ifdef USE_INTERNAL_EDIT
     if (macros_list != NULL)
     {
         guint i;
@@ -464,6 +467,7 @@ main (int argc, char *argv[])
         }
         (void) g_array_free (macros_list, TRUE);
     }
+#endif /* USE_INTERNAL_EDIT */
 
     str_uninit_strings ();
 

+ 2 - 0
src/setup.c

@@ -203,6 +203,7 @@ int quit = 0;
 /* Set to TRUE to suppress printing the last directory */
 int print_last_revert = FALSE;
 
+#ifdef USE_INTERNAL_EDIT
 /* index to record_macro_buf[], -1 if not recording a macro */
 int macro_index = -1;
 
@@ -210,6 +211,7 @@ int macro_index = -1;
 struct macro_action_t record_macro_buf[MAX_MACRO_LENGTH];
 
 GArray *macros_list;
+#endif /* USE_INTERNAL_EDIT */
 
 /*** file scope macro definitions ****************************************************************/
 

+ 2 - 0
src/setup.h

@@ -126,6 +126,7 @@ extern int quit;
 /* Set to TRUE to suppress printing the last directory */
 extern gboolean print_last_revert;
 
+#ifdef USE_INTERNAL_EDIT
 /* index to record_macro_buf[], -1 if not recording a macro */
 extern int macro_index;
 
@@ -133,6 +134,7 @@ extern int macro_index;
 extern struct macro_action_t record_macro_buf[MAX_MACRO_LENGTH];
 
 extern GArray *macros_list;
+#endif /* USE_INTERNAL_EDIT */
 
 extern int saving_setup;