Project

General

Profile

Bug #10371

vfs: cast between incompatible function types

Added by Toomas Soome 8 months ago. Updated 8 months ago.

Status:
Closed
Priority:
Normal
Assignee:
Category:
kernel
Start date:
2019-02-11
Due date:
% Done:

100%

Estimated time:
Difficulty:
Medium
Tags:

Description

Build error from gcc 8:

    ../../common/fs/vfs.c: In function 'fs_copyfsops':
    ../../common/fs/vfs.c:351:4: error: cast between incompatible function types from 'void (*)(vfs_t *)' {aka 'void (*)(struct vfs *)'} to 'int (*)()' [-Werror=cast-function-type]
        (fs_generic_func_p)fs_freevfs,
        ^
    ../../common/fs/vfs.c:352:4: error: cast between incompatible function types from 'void (*)(vfs_t *)' {aka 'void (*)(struct vfs *)'} to 'int (*)()' [-Werror=cast-function-type]
        (fs_generic_func_p)fs_freevfs, /* Shouldn't fail */
        ^
    cc1: all warnings being treated as errors

cast over uintptr_t.

History

#1

Updated by Electric Monk 8 months ago

  • % Done changed from 90 to 100
  • Status changed from In Progress to Closed

git commit b6d49c8438f976a7c4a6c9390228076c8f132847

commit  b6d49c8438f976a7c4a6c9390228076c8f132847
Author: Toomas Soome <tsoome@me.com>
Date:   2019-02-20T19:24:56.000Z

    10371 vfs: cast between incompatible function types
    Reviewed by: Andy Stormont <astormont@racktopsystems.com>
    Reviewed by: C Fraire <cfraire@me.com>
    Reviewed by: Gergő Doma <domag02@gmail.com>

Also available in: Atom PDF