Index: sql/diagnostic_error_delegate.h |
=================================================================== |
--- sql/diagnostic_error_delegate.h (revision 151481) |
+++ sql/diagnostic_error_delegate.h (working copy) |
@@ -12,6 +12,10 @@ |
namespace sql { |
+// The histogram values from sqlite result codes currently range from 1 to 26 |
+// but 50 gives them room to grow. |
+static const int kMaxSqliteError = 50; |
+ |
// This class handles the exceptional sqlite errors that we might encounter |
// if for example the db is corrupted. Right now we just generate a UMA |
// histogram for release and an assert for debug builds. |
@@ -39,9 +43,7 @@ |
// Trim off the extended error codes. |
error &= 0xff; |
- // The histogram values from sqlite result codes go currently from 1 to |
- // 26 currently but 50 gives them room to grow. |
- UMA_HISTOGRAM_ENUMERATION(UniqueT::name(), error, 50); |
+ UMA_HISTOGRAM_ENUMERATION(UniqueT::name(), error, kMaxSqliteError); |
} |
}; |