Skip to content

Commit 8bd8032

Browse files
committed
Resolve gcc "warning: comparison between signed and unsigned integer expressions [-Wsign-compare]"
1 parent a7e49f5 commit 8bd8032

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

Release/include/cpprest/filestream.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -360,7 +360,7 @@ namespace details {
360360

361361
size_t written = _putn_fsb(m_info, callback, ptr, count, sizeof(_CharType));
362362

363-
if ( written != 0 && written != -1 )
363+
if ( written != 0 && written != size_t(-1) )
364364
{
365365
delete callback;
366366
written = written/sizeof(_CharType);
@@ -572,7 +572,7 @@ namespace details {
572572

573573
size_t read = _getn_fsb(m_info, callback, ptr, count, sizeof(_CharType));
574574

575-
if ( read != 0 && read != -1)
575+
if ( read != 0 && read != size_t(-1) )
576576
{
577577
delete callback;
578578
pplx::extensibility::scoped_recursive_lock_t lck(m_info->m_lock);

0 commit comments

Comments
 (0)