summaryrefslogtreecommitdiffstats
path: root/src/util.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/util.cpp')
-rw-r--r--src/util.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/util.cpp b/src/util.cpp
index 37977f2..eb6425d 100644
--- a/src/util.cpp
+++ b/src/util.cpp
@@ -29,7 +29,7 @@ void rectangle::fit(unsigned long to_width, unsigned long to_height)
{
// fit rect within (to_width x to_height)
- if (to_width <= width()) {
+ if (to_width <= (unsigned long)width()) {
// scale to fit with
set_bottom(top() + (static_cast<long>(to_width) * height() / width()) - 1);
set_right(left() + to_width - 1);
@@ -139,4 +139,4 @@ void _DUMP(enum LOG_LEVEL level, const char *log, ...)
fprintf(stderr, "%s \n", message);
va_end(args);
free(message);
-} \ No newline at end of file
+}