add optional length to parseInt() and set result on success, remove unused stuff, avoid reading beyond eof, check divisor in StringDataField::derive(), fix for NumberDataField::writeSymbols()
This commit is contained in:
Regular → Executable
+2
-1
@@ -71,8 +71,9 @@ typedef struct {
|
||||
* @param minValue the minimum resulting value.
|
||||
* @param maxValue the maximum resulting value.
|
||||
* @param result the variable in which to store an error code when parsing failed or the value is out of bounds.
|
||||
* @param length the optional variable in which to store the number of read characters.
|
||||
*/
|
||||
unsigned int parseInt(const char* str, int base, const unsigned int minValue, const unsigned int maxValue, result_t& result);
|
||||
unsigned int parseInt(const char* str, int base, const unsigned int minValue, const unsigned int maxValue, result_t& result, unsigned int* length=NULL);
|
||||
|
||||
|
||||
class SingleDataField;
|
||||
|
||||
Reference in New Issue
Block a user