From 35f139d319388814bc570db6236e705cf19456c2 Mon Sep 17 00:00:00 2001
From: Andreas Mohr <and@gmx.li>
Date: Sat, 5 Jan 2019 18:53:53 +0000
Subject: [PATCH] editcmd_dialogs.c: Cleanup -Wcast-align warning
Found by Clang 6.0.1
editcmd_dialogs.c:474:20: warning: cast from 'char *' to 'etags_hash_t *' (aka 'struct etags_hash_struct *') increases required alignment from 1 to 8 [-Wcast-align]
curr_def = (etags_hash_t *) tmp_curr_def;
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Signed-off-by: Andreas Mohr <and@gmx.li>
---
src/editor/editcmd_dialogs.c | 6 ++----
1 file changed, 2 insertions(+), 4 deletions(-)
diff --git a/src/editor/editcmd_dialogs.c b/src/editor/editcmd_dialogs.c
index ed17afeb1..cf60b00d3 100644
a
|
b
|
editcmd_dialog_select_definition_show (WEdit * edit, char *match_expr, int max_l |
414 | 414 | |
415 | 415 | int start_x, start_y, offset, i; |
416 | 416 | char *curr = NULL; |
417 | | etags_hash_t *curr_def = NULL; |
418 | 417 | WDialog *def_dlg; |
419 | 418 | WListbox *def_list; |
420 | 419 | int def_dlg_h; /* dialog height */ |
… |
… |
editcmd_dialog_select_definition_show (WEdit * edit, char *match_expr, int max_l |
467 | 466 | /* pop up the dialog and apply the chosen completion */ |
468 | 467 | if (dlg_run (def_dlg) == B_ENTER) |
469 | 468 | { |
470 | | char *tmp_curr_def = (char *) curr_def; |
| 469 | etags_hash_t *curr_def = NULL; |
471 | 470 | int do_moveto = 0; |
472 | 471 | |
473 | | listbox_get_current (def_list, &curr, (void **) &tmp_curr_def); |
474 | | curr_def = (etags_hash_t *) tmp_curr_def; |
| 472 | listbox_get_current (def_list, &curr, (void **) &curr_def); |
475 | 473 | if (edit->modified) |
476 | 474 | { |
477 | 475 | if (!edit_query_dialog2 |