Ticket #4179: mc-4179-libcheck-fail-deprecated.patch

File mc-4179-libcheck-fail-deprecated.patch, 1.5 KB (added by and, 3 years ago)
  • tests/lib/mcconfig/config_string.c

    From e3fda87df915fde1d2ac95f2fde604f30c38ea9d Mon Sep 17 00:00:00 2001
    From: Andreas Mohr <and@gmx.li>
    Date: Mon, 28 Dec 2020 17:58:59 +0000
    Subject: [PATCH] libcheck: replace deprecated fail() function
    
    libcheck fail() is deprecated since 0.10.0
    also fix -Wformat-extra-args warnings
    
    Signed-off-by: Andreas Mohr <and@gmx.li>
    ---
     tests/lib/mcconfig/config_string.c | 2 +-
     tests/lib/vfs/vfs_parse_ls_lga.c   | 2 +-
     2 files changed, 2 insertions(+), 2 deletions(-)
    
    diff --git a/tests/lib/mcconfig/config_string.c b/tests/lib/mcconfig/config_string.c
    index da479de59..26f9254a9 100644
    a b config_object__reopen (void) 
    5656 
    5757    if (!mc_config_save_file (mc_config, &error)) 
    5858    { 
    59         fail ("Unable to save config file: %s", error->message); 
     59        ck_abort_msg ("Unable to save config file: %s", error->message); 
    6060        g_error_free (error); 
    6161    } 
    6262 
  • tests/lib/vfs/vfs_parse_ls_lga.c

    diff --git a/tests/lib/vfs/vfs_parse_ls_lga.c b/tests/lib/vfs/vfs_parse_ls_lga.c
    index b1b203af5..1968190a6 100644
    a b END_TEST 
    365365    if (! vfs_parse_ls_lga (ls_output,\ 
    366366    &ent[ent_index]->ino->st, &ent[ent_index]->name, &ent[ent_index]->ino->linkname, &filepos))\ 
    367367    {\ 
    368         fail ("An error occurred while parse ls output");\ 
     368        ck_abort_msg ("An error occurred while parse ls output");\ 
    369369        return;\ 
    370370    }\ 
    371371    vfs_s_store_filename_leading_spaces (ent[ent_index], filepos);\