Opened 3 years ago

Closed 3 years ago

#12995 closed bug (fixed)

[Patch]Database.cpp: Fix int-in-bool-context warning.

Reported by: mt Owned by: axeld
Priority: normal Milestone: Unscheduled
Component: Kits/Storage Kit Version: R1/Development
Keywords: Cc:
Blocked By: Blocking:
Has a Patch: yes Platform: All

Description

At line 1142 [1], _SendMonitorUpdate() requires boolean [2], but we passed icon_size.

[1] http://cgit.haiku-os.org/haiku/tree/src/kits/storage/mime/Database.cpp#n1142 [2] http://cgit.haiku-os.org/haiku/tree/src/kits/storage/mime/Database.cpp#n1458

/home/haiku/haiku/haiku/src/kits/storage/mime/Database.cpp: In member function 'status_t BPrivate::Storage::Mime::Database::DeleteIcon(const char*)':
/home/haiku/haiku/haiku/src/kits/storage/mime/Database.cpp:1142:29: error: enum constant in boolean context [-Werror=int-in-bool-context]
          B_META_MIME_DELETED);
                             ^

Attachments (1)

0038-Database.cpp-Fix-int-in-bool-context-warning.patch (1.1 KB) - added by mt 3 years ago.

Download all attachments as: .zip

Change History (3)

comment:1 Changed 3 years ago by mt

Has a Patch: set

comment:2 Changed 3 years ago by pulkomandy

Resolution: fixed
Status: newclosed

Applied (with an extra similar change) in hrev50584.

Note: See TracTickets for help on using tickets.