summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLloyd Hilaiel <me@lloyd.io>2014-03-17 07:43:08 +0200
committerLloyd Hilaiel <me@lloyd.io>2014-03-17 07:43:08 +0200
commitca5ca36d9bb738c28ff54feb01dd99de2244f2fd (patch)
treedb5e21949627816caee816fd517931235dd411d8
parent263adf537abb02300738bb96e551f7002a8582df (diff)
downloadyajl-ca5ca36d9bb738c28ff54feb01dd99de2244f2fd.tar.gz
typos and formatting
-rw-r--r--src/api/yajl_tree.h6
-rw-r--r--src/yajl_tree.c2
2 files changed, 4 insertions, 4 deletions
diff --git a/src/api/yajl_tree.h b/src/api/yajl_tree.h
index 729c579..5d06879 100644
--- a/src/api/yajl_tree.h
+++ b/src/api/yajl_tree.h
@@ -67,7 +67,7 @@ typedef struct yajl_val_s * yajl_val;
*/
struct yajl_val_s
{
- /** Type of the value contained. Use the "YAJL_IS_*" macors to check for a
+ /** Type of the value contained. Use the "YAJL_IS_*" macros to check for a
* specific type. */
yajl_type type;
/** Type-specific data. You may use the "YAJL_GET_*" macros to access these
@@ -78,10 +78,10 @@ struct yajl_val_s
struct {
long long i; /*< integer value, if representable. */
double d; /*< double value, if representable. */
+ char *r; /*< unparsed number in string form. */
/** Signals whether the \em i and \em d members are
* valid. See \c YAJL_NUMBER_INT_VALID and
* \c YAJL_NUMBER_DOUBLE_VALID. */
- char *r; /*< unparsed number in string form. */
unsigned int flags;
} number;
struct {
@@ -137,7 +137,7 @@ YAJL_API void yajl_tree_free (yajl_val v);
* \param type the yajl_type of the object you seek, or yajl_t_any if any will do.
*
* \returns a pointer to the found value, or NULL if we came up empty.
- *
+ *
* Future Ideas: it'd be nice to move path to a string and implement support for
* a teeny tiny micro language here, so you can extract array elements, do things
* like .first and .last, even .length. Inspiration from JSONPath and css selectors?
diff --git a/src/yajl_tree.c b/src/yajl_tree.c
index f486e89..3d357a3 100644
--- a/src/yajl_tree.c
+++ b/src/yajl_tree.c
@@ -194,7 +194,7 @@ static int array_add_value (context_t *ctx,
/* "context_add_value" will only call us with array values. */
assert(YAJL_IS_ARRAY(array));
-
+
tmp = realloc(array->u.array.values,
sizeof(*(array->u.array.values)) * (array->u.array.len + 1));
if (tmp == NULL)