Permalink
Browse files

Fix compilation warning on NetBSD: issue #593.

  • Loading branch information...
1 parent d744c84 commit bb0c938480852495e53d9544cf1616e17ef80594 @FooBarWidget FooBarWidget committed Dec 8, 2010
Showing with 2 additions and 1 deletion.
  1. +2 −1 ext/common/Utils/StrIntUtils.cpp
@@ -26,6 +26,7 @@
#include <cstdio>
#include <cstdlib>
#include <cctype>
+#include <cmath>
#include <Utils/utf8.h>
#include <Exceptions.h>
#include <Utils/StrIntUtils.h>
@@ -322,7 +323,7 @@ cEscapeString(const StaticString &input) {
string
escapeHTML(const StaticString &input) {
string result;
- result.reserve(input.size() * 1.25);
+ result.reserve((int) round(input.size() * 1.25));
const char *current = (const char *) input.c_str();
const char *end = current + input.size();

0 comments on commit bb0c938

Please sign in to comment.