Project

General

Profile

Bug #8897

OSD: get_max_object_name_length() int versus uint

Added by Greg Farnum about 5 years ago. Updated about 5 years ago.

Status:
Resolved
Priority:
Normal
Assignee:
Category:
OSD
Target version:
-
Start date:
07/22/2014
Due date:
% Done:

0%

Source:
Development
Tags:
Backport:
Regression:
No
Severity:
3 - minor
Reviewed:
Affected Versions:
ceph-qa-suite:
Pull request ID:

Description

We have a build warning now for signed/unsigned comparison warnings in the OSD now. It's a comparison between osd_max_object_name_len (unsigned) and the ObjectStore::get_max_object_name_len() (signed). Unfortunately, the KeyValueStore backend actually uses that negative range to return error codes (on some syscall?), so the MIN isn't really even safe. :/
Not sure how we care to resolve this.

Associated revisions

Revision 253ca2b9 (diff)
Added by Sage Weil about 5 years ago

os: make name/attr max methods unsigned

This fixes warnings when we use these in MIN/MAX macros against
other unsigned values.

Fixes: #8897
Signed-off-by: Sage Weil <>

History

#1 Updated by Sage Weil about 5 years ago

  • Status changed from New to Need Review

#2 Updated by Greg Farnum about 5 years ago

  • Status changed from Need Review to Resolved

Also available in: Atom PDF