/*
- * Copyright (c) 2009 Petri Lehtinen <petri@digip.org>
+ * Copyright (c) 2009, 2010 Petri Lehtinen <petri@digip.org>
*
* Jansson is free software; you can redistribute it and/or modify
* it under the terms of the MIT license. See LICENSE for details.
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
-#include <stdint.h>
#include <assert.h>
#include <jansson.h>
if(dump("[", 1, data))
return -1;
- if(n == 0)
+ if(n == 0) {
+ array->visited = 0;
return dump("]", 1, data);
+ }
if(dump_indent(flags, depth + 1, 0, dump, data))
return -1;
if(dump("{", 1, data))
return -1;
- if(!iter)
+ if(!iter) {
+ object->visited = 0;
return dump("}", 1, data);
+ }
if(dump_indent(flags, depth + 1, 0, dump, data))
return -1;