Skip to content

Commit

Permalink
Fix build when dired disabled
Browse files Browse the repository at this point in the history
* src/funmap.c:
* src/keymap.c: Guard references to `dired_jump` function and its
  implementation behind `ENABLE_DIRED` preprocessor maco.

Fixes linker error when building with `--disable-dired` configuration
option and those that imply it.
  • Loading branch information
g-branden-robinson committed Feb 18, 2024
1 parent ca4d8a1 commit f3da7b6
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/funmap.c
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,9 @@ static struct funmap functnames[] = {
{desckey, "describe-key-briefly", 1, NULL},
{diffbuffer, "diff-buffer-with-file", 0, NULL},
{digit_argument, "digit-argument", 1, NULL},
#ifdef ENABLE_DIRED
{dired_jump, "dired-jump", 1, NULL},
#endif
{helptoggle, "display-help-mode", 0, NULL},
{timetoggle, "display-time-mode", 0, NULL},
{lowerregion, "downcase-region", 0, NULL},
Expand Down
2 changes: 2 additions & 0 deletions src/keymap.c
Original file line number Diff line number Diff line change
Expand Up @@ -157,7 +157,9 @@ static PF cXcB[] = {
};

static PF cXcJ[] = {
#ifdef ENABLE_DIRED
dired_jump, /* ^J */
#endif
rescan, /* ^K */
lowerregion, /* ^L */
rescan, /* ^M */
Expand Down

0 comments on commit f3da7b6

Please sign in to comment.