Ticket #3463: mc-3463-cleanup-bad_function_cast-warning.patch

File mc-3463-cleanup-bad_function_cast-warning.patch, 1.6 KB (added by and, 9 years ago)
  • m4.include/mc-cflags.m4

    fix -Wbad-function-cast warnings and add to mc cflags
    
    file.c: In function 'do_compute_dir_size':
    file.c:584:23: error: cast from function call of type 'int' to non-matching type 'enum <anonymous>' [-Wbad-function-cast]
    file.c: In function 'real_query_recursive':
    file.c:717:13: error: cast from function call of type 'int' to non-matching type 'enum <anonymous>' [-Wbad-function-cast]
    
    Signed-off-by: Andreas Mohr <and@gmx.li>
    
    a b  
    5252esac 
    5353 
    5454dnl Sorted -W options: 
    55 dnl    MC_CHECK_ONE_CFLAG([-Wbad-function-cast]) 
     55    MC_CHECK_ONE_CFLAG([-Wbad-function-cast]) 
    5656    MC_CHECK_ONE_CFLAG([-Wcomment]) 
    5757    MC_CHECK_ONE_CFLAG([-Wdeclaration-after-statement]) 
    5858    MC_CHECK_ONE_CFLAG([-Wfloat-equal]) 
  • src/filemanager/file.c

    
            
    a b  
    581581                dsm->dirname_vpath = tmp_vpath; 
    582582                dsm->dir_count = *dir_count; 
    583583                dsm->total_size = *ret_total; 
    584                 ret = (FileProgressStatus) sm->update (sm); 
     584                ret = sm->update (sm); 
    585585            } 
    586586        } 
    587587 
     
    714714            query_set_sel (1); 
    715715 
    716716        ctx->recursive_result = 
    717             (FileCopyMode) query_dialog (op_names[OP_DELETE], text, D_ERROR, 5, 
    718                                          _("&Yes"), _("&No"), _("A&ll"), _("Non&e"), _("&Abort")); 
     717            query_dialog (op_names[OP_DELETE], text, D_ERROR, 5, 
     718                          _("&Yes"), _("&No"), _("A&ll"), _("Non&e"), _("&Abort")); 
    719719        g_free (text); 
    720720 
    721721        if (ctx->recursive_result != RECURSIVE_ABORT)