summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorLauri Aalto <laalto@iki.fi>2010-02-05 12:45:44 +0200
committerLauri Aalto <laalto@iki.fi>2010-02-09 11:20:17 +0200
commitf70f153e099ccc9c0280ae6cbcf771ecae4dfc46 (patch)
tree978ad787fc3f81b193dadb199087c81a65b0417d /src
parent7d2b19e79b87a16fbf929437e7273f88e5230aa4 (diff)
downloadraptor-f70f153e099ccc9c0280ae6cbcf771ecae4dfc46.tar.gz
indent + whitespace
Diffstat (limited to 'src')
-rw-r--r--src/raptor_rss.c12
-rw-r--r--src/raptor_sax2.c4
-rw-r--r--src/raptor_serialize.c4
-rw-r--r--src/raptor_serialize_json.c12
-rw-r--r--src/raptor_serialize_rdfxml.c34
-rw-r--r--src/raptor_serialize_rdfxmla.c14
-rw-r--r--src/raptor_serialize_rss.c12
-rw-r--r--src/raptor_serialize_turtle.c14
-rw-r--r--src/raptor_set.c4
-rw-r--r--src/raptor_uri.c4
-rw-r--r--src/raptor_xml.c2
-rw-r--r--src/raptor_xml_writer.c4
12 files changed, 60 insertions, 60 deletions
diff --git a/src/raptor_rss.c b/src/raptor_rss.c
index 9aef80fb..9effc78b 100644
--- a/src/raptor_rss.c
+++ b/src/raptor_rss.c
@@ -245,8 +245,8 @@ raptor_rss_parse_start(raptor_parser *rdf_parser)
/* Optionally forbid network requests in the XML parser */
raptor_sax2_set_option(rss_parser->sax2,
- RAPTOR_OPTION_NO_NET,
- rdf_parser->options[RAPTOR_OPTION_NO_NET]);
+ RAPTOR_OPTION_NO_NET,
+ rdf_parser->options[RAPTOR_OPTION_NO_NET]);
raptor_sax2_parse_start(rss_parser->sax2, uri);
@@ -507,7 +507,7 @@ raptor_rss_start_element_handler(void *user_data,
field_nspace_URI = rdf_parser->world->rss_namespaces_info_uris[raptor_rss_fields_info[i].nspace];
if(raptor_uri_equals(nspace_URI,
- field_nspace_URI)) {
+ field_nspace_URI)) {
rss_parser->current_field = (raptor_rss_fields_type)i;
break;
}
@@ -617,7 +617,7 @@ raptor_rss_start_element_handler(void *user_data,
if(!strcmp((const char*)attrValue, "true")) {
RAPTOR_DEBUG2(" setting guid to URI '%s'\n", attrValue);
field->uri = raptor_new_uri_relative_to_base(rdf_parser->world, base_uri,
- (const unsigned char*)attrValue);
+ (const unsigned char*)attrValue);
} else {
size_t len = strlen((const char*)attrValue);
RAPTOR_DEBUG2(" setting guid to string '%s'\n", attrValue);
@@ -637,7 +637,7 @@ raptor_rss_start_element_handler(void *user_data,
if(rss_element->uri)
raptor_free_uri(rss_element->uri);
rss_element->uri = raptor_new_uri_relative_to_base(rdf_parser->world, base_uri,
- (const unsigned char*)attrValue);
+ (const unsigned char*)attrValue);
}
} else if(!strcmp((const char*)attrName, "type")) {
if(rss_parser->current_field == RAPTOR_RSS_FIELD_ATOM_LINK) {
@@ -660,7 +660,7 @@ raptor_rss_start_element_handler(void *user_data,
NULL,
rss_element->iostream);
raptor_xml_writer_set_option(rss_element->xml_writer,
- RAPTOR_OPTION_WRITER_XML_DECLARATION, 0);
+ RAPTOR_OPTION_WRITER_XML_DECLARATION, 0);
raptor_free_stringbuffer(rss_element->sb);
rss_element->sb = NULL;
diff --git a/src/raptor_sax2.c b/src/raptor_sax2.c
index 2427edd3..d014040e 100644
--- a/src/raptor_sax2.c
+++ b/src/raptor_sax2.c
@@ -831,8 +831,8 @@ raptor_sax2_start_element(void* user_data, const unsigned char *name,
raptor_namespace* nspace;
nspace = raptor_new_namespace(&sax2->namespaces,
- prefix, namespace_name,
- raptor_sax2_get_depth(sax2));
+ prefix, namespace_name,
+ raptor_sax2_get_depth(sax2));
if(nspace) {
raptor_namespaces_start_namespace(&sax2->namespaces, nspace);
diff --git a/src/raptor_serialize.c b/src/raptor_serialize.c
index 922350c2..b79b7aa0 100644
--- a/src/raptor_serialize.c
+++ b/src/raptor_serialize.c
@@ -184,7 +184,7 @@ raptor_serializer_register_factory(raptor_world* world,
serializer = (raptor_serializer_factory*)RAPTOR_CALLOC(raptor_serializer_factory, 1,
- sizeof(*serializer));
+ sizeof(*serializer));
if(!serializer)
return 1;
@@ -313,7 +313,7 @@ raptor_world_enumerate_serializers(raptor_world* world,
raptor_serializer_factory *factory;
factory = (raptor_serializer_factory*)raptor_sequence_get_at(world->serializers,
- counter);
+ counter);
if(!factory)
return 1;
diff --git a/src/raptor_serialize_json.c b/src/raptor_serialize_json.c
index a4dc7568..b430ab55 100644
--- a/src/raptor_serialize_json.c
+++ b/src/raptor_serialize_json.c
@@ -501,12 +501,12 @@ raptor_init_serializer_json(raptor_world* world)
int rc;
rc = raptor_serializer_register_factory(world,
- "json-triples",
- "RDF/JSON Triples",
- "application/json",
- NULL,
- NULL,
- &raptor_json_triples_serializer_register_factory);
+ "json-triples",
+ "RDF/JSON Triples",
+ "application/json",
+ NULL,
+ NULL,
+ &raptor_json_triples_serializer_register_factory);
if(rc)
return rc;
diff --git a/src/raptor_serialize_rdfxml.c b/src/raptor_serialize_rdfxml.c
index d279effc..01ca0b15 100644
--- a/src/raptor_serialize_rdfxml.c
+++ b/src/raptor_serialize_rdfxml.c
@@ -90,14 +90,14 @@ raptor_rdfxml_serialize_init(raptor_serializer* serializer, const char *name)
if(!context->nstack)
return 1;
context->xml_nspace = raptor_new_namespace(context->nstack,
- (const unsigned char*)"xml",
- (const unsigned char*)raptor_xml_namespace_uri,
- 0);
+ (const unsigned char*)"xml",
+ (const unsigned char*)raptor_xml_namespace_uri,
+ 0);
context->rdf_nspace = raptor_new_namespace(context->nstack,
- (const unsigned char*)"rdf",
- (const unsigned char*)raptor_rdf_namespace_uri,
- 0);
+ (const unsigned char*)"rdf",
+ (const unsigned char*)raptor_rdf_namespace_uri,
+ 0);
context->namespaces = raptor_new_sequence(NULL, NULL);
@@ -193,8 +193,8 @@ raptor_rdfxml_serialize_declare_namespace_from_namespace(raptor_serializer* seri
}
nspace = raptor_new_namespace_from_uri(context->nstack,
- nspace->prefix, nspace->uri,
- RDFXML_NAMESPACE_DEPTH);
+ nspace->prefix, nspace->uri,
+ RDFXML_NAMESPACE_DEPTH);
if(!nspace)
return 1;
@@ -214,10 +214,10 @@ raptor_rdfxml_serialize_declare_namespace(raptor_serializer* serializer,
int rc;
ns = raptor_new_namespace_from_uri(context->nstack, prefix, uri,
- RDFXML_NAMESPACE_DEPTH);
+ RDFXML_NAMESPACE_DEPTH);
rc = raptor_rdfxml_serialize_declare_namespace_from_namespace(serializer,
- ns);
+ ns);
raptor_free_namespace(ns);
return rc;
@@ -241,10 +241,10 @@ raptor_rdfxml_serialize_start(raptor_serializer* serializer)
if(!xml_writer)
return 1;
raptor_xml_writer_set_option(xml_writer, RAPTOR_OPTION_WRITER_XML_VERSION,
- serializer->xml_version);
+ serializer->xml_version);
raptor_xml_writer_set_option(xml_writer,
- RAPTOR_OPTION_WRITER_XML_DECLARATION,
- serializer->option_write_xml_declaration);
+ RAPTOR_OPTION_WRITER_XML_DECLARATION,
+ serializer->option_write_xml_declaration);
context->xml_writer = xml_writer;
context->written_header = 0;
@@ -363,7 +363,7 @@ raptor_rdfxml_serialize_statement(raptor_serializer* serializer,
/* Do not use raptor_uri_as_counted_string() - we want a modifiable copy */
uri_string = raptor_uri_to_counted_string(statement->predicate->value.uri,
- &uri_len);
+ &uri_len);
if(!uri_string)
goto oom;
@@ -392,11 +392,11 @@ raptor_rdfxml_serialize_statement(raptor_serializer* serializer,
*name=c;
predicate_ns = raptor_namespaces_find_namespace_by_uri(context->nstack,
- predicate_ns_uri);
+ predicate_ns_uri);
if(!predicate_ns) {
predicate_ns = raptor_new_namespace_from_uri(context->nstack,
- nsprefix,
- predicate_ns_uri, 0);
+ nsprefix,
+ predicate_ns_uri, 0);
if(!predicate_ns) {
raptor_free_uri(predicate_ns_uri);
goto oom;
diff --git a/src/raptor_serialize_rdfxmla.c b/src/raptor_serialize_rdfxmla.c
index 84c923e7..3c9e18ab 100644
--- a/src/raptor_serialize_rdfxmla.c
+++ b/src/raptor_serialize_rdfxmla.c
@@ -1189,17 +1189,17 @@ raptor_rdfxmla_serialize_start(raptor_serializer* serializer)
return 1;
raptor_xml_writer_set_option(xml_writer,
- RAPTOR_OPTION_WRITER_AUTO_INDENT, 1);
+ RAPTOR_OPTION_WRITER_AUTO_INDENT, 1);
raptor_xml_writer_set_option(xml_writer,
- RAPTOR_OPTION_WRITER_AUTO_EMPTY, 1);
+ RAPTOR_OPTION_WRITER_AUTO_EMPTY, 1);
raptor_xml_writer_set_option(xml_writer,
- RAPTOR_OPTION_WRITER_INDENT_WIDTH,2);
+ RAPTOR_OPTION_WRITER_INDENT_WIDTH,2);
raptor_xml_writer_set_option(xml_writer,
- RAPTOR_OPTION_WRITER_XML_VERSION,
- serializer->xml_version);
+ RAPTOR_OPTION_WRITER_XML_VERSION,
+ serializer->xml_version);
raptor_xml_writer_set_option(xml_writer,
- RAPTOR_OPTION_WRITER_XML_DECLARATION,
- serializer->option_write_xml_declaration);
+ RAPTOR_OPTION_WRITER_XML_DECLARATION,
+ serializer->option_write_xml_declaration);
context->xml_writer = xml_writer;
}
diff --git a/src/raptor_serialize_rss.c b/src/raptor_serialize_rss.c
index 049eb7b4..c9f437e4 100644
--- a/src/raptor_serialize_rss.c
+++ b/src/raptor_serialize_rss.c
@@ -200,8 +200,8 @@ raptor_rss10_serialize_init(raptor_serializer* serializer, const char *name)
rss_serializer->enclosures = raptor_new_sequence((raptor_data_free_handler*)raptor_free_rss_item, (raptor_data_print_handler*)NULL);
rss_serializer->group_map = raptor_new_avltree(serializer->world,
- (raptor_data_compare_function)raptor_rss_group_map_compare,
- (raptor_data_free_function)raptor_free_group_map, 0);
+ (raptor_data_compare_function)raptor_rss_group_map_compare,
+ (raptor_data_free_function)raptor_free_group_map, 0);
rss_serializer->user_namespaces = raptor_new_sequence((raptor_data_free_handler*)raptor_free_namespace, NULL);
@@ -2039,9 +2039,9 @@ raptor_rss10_serialize_end(raptor_serializer* serializer) {
serializer->iostream);
rss_serializer->xml_writer = xml_writer;
raptor_xml_writer_set_option(xml_writer,
- RAPTOR_OPTION_WRITER_AUTO_INDENT, 1);
+ RAPTOR_OPTION_WRITER_AUTO_INDENT, 1);
raptor_xml_writer_set_option(xml_writer,
- RAPTOR_OPTION_WRITER_AUTO_EMPTY, 1);
+ RAPTOR_OPTION_WRITER_AUTO_EMPTY, 1);
raptor_rss10_build_xml_names(serializer, (is_atom && entry_uri));
@@ -2145,8 +2145,8 @@ raptor_rss10_serialize_declare_namespace_from_namespace(raptor_serializer* seria
}
nspace = raptor_new_namespace_from_uri(rss_serializer->nstack,
- nspace->prefix, nspace->uri,
- 0);
+ nspace->prefix, nspace->uri,
+ 0);
if(!nspace)
return 1;
diff --git a/src/raptor_serialize_turtle.c b/src/raptor_serialize_turtle.c
index 6d33fab8..d0ecff1f 100644
--- a/src/raptor_serialize_turtle.c
+++ b/src/raptor_serialize_turtle.c
@@ -785,9 +785,9 @@ raptor_turtle_serialize_init(raptor_serializer* serializer, const char *name)
if(!context->nstack)
return 1;
context->rdf_nspace = raptor_new_namespace(context->nstack,
- (const unsigned char*)"rdf",
- (const unsigned char*)raptor_rdf_namespace_uri,
- 0);
+ (const unsigned char*)"rdf",
+ (const unsigned char*)raptor_rdf_namespace_uri,
+ 0);
context->namespaces = raptor_new_sequence(NULL, NULL);
@@ -948,8 +948,8 @@ raptor_turtle_serialize_declare_namespace_from_namespace(raptor_serializer* seri
}
nspace = raptor_new_namespace_from_uri(context->nstack,
- nspace->prefix, nspace->uri,
- TURTLE_NAMESPACE_DEPTH);
+ nspace->prefix, nspace->uri,
+ TURTLE_NAMESPACE_DEPTH);
if(!nspace)
return 1;
@@ -997,9 +997,9 @@ raptor_turtle_serialize_start(raptor_serializer* serializer)
return 1;
raptor_turtle_writer_set_option(turtle_writer,
- RAPTOR_OPTION_WRITER_AUTO_INDENT,1);
+ RAPTOR_OPTION_WRITER_AUTO_INDENT,1);
raptor_turtle_writer_set_option(turtle_writer,
- RAPTOR_OPTION_WRITER_INDENT_WIDTH,2);
+ RAPTOR_OPTION_WRITER_INDENT_WIDTH,2);
context->turtle_writer = turtle_writer;
diff --git a/src/raptor_set.c b/src/raptor_set.c
index 320bd7ef..ea302a2b 100644
--- a/src/raptor_set.c
+++ b/src/raptor_set.c
@@ -195,8 +195,8 @@ raptor_id_set_add(raptor_id_set* set, raptor_uri *base_uri,
base->uri = raptor_uri_copy(base_uri);
base->tree = raptor_new_avltree(set->world,
- (raptor_data_compare_function)strcmp,
- free, 0);
+ (raptor_data_compare_function)strcmp,
+ free, 0);
/* Add to the start of the list */
if(set->first)
diff --git a/src/raptor_uri.c b/src/raptor_uri.c
index 899685a5..7a89ffc4 100644
--- a/src/raptor_uri.c
+++ b/src/raptor_uri.c
@@ -1190,7 +1190,7 @@ raptor_uri_to_relative_counted_uri_string(raptor_uri *base_uri,
reference_file++;
reference_file_len = reference_detail->path_len -
- (reference_file - reference_detail->path);
+ (reference_file - reference_detail->path);
if(!strcmp((const char*)base_file, (const char*)reference_file)) {
/* If the file names are equal, don't put them in the relative URI */
@@ -1207,7 +1207,7 @@ raptor_uri_to_relative_counted_uri_string(raptor_uri *base_uri,
addqueryfragment:
/* Calculate the length of the suffix (file name + query + fragment) */
suffix_len = reference_file_len + reference_detail->query_len +
- reference_detail->fragment_len;
+ reference_detail->fragment_len;
if(reference_detail->query)
suffix_len++; /* add one char for the '?' */
diff --git a/src/raptor_xml.c b/src/raptor_xml.c
index a9f09185..36dbebc7 100644
--- a/src/raptor_xml.c
+++ b/src/raptor_xml.c
@@ -68,7 +68,7 @@ raptor_new_xml_element(raptor_qname *name,
raptor_xml_element* xml_element;
xml_element = (raptor_xml_element*)RAPTOR_CALLOC(raptor_xml_element, 1,
- sizeof(*xml_element));
+ sizeof(*xml_element));
if(!xml_element)
return NULL;
diff --git a/src/raptor_xml_writer.c b/src/raptor_xml_writer.c
index 55f2d0e6..f546f3bd 100644
--- a/src/raptor_xml_writer.c
+++ b/src/raptor_xml_writer.c
@@ -60,7 +60,7 @@ typedef enum {
#define XML_WRITER_AUTO_EMPTY(xml_writer) ((xml_writer->flags & XML_WRITER_AUTO_EMPTY) != 0)
#define XML_WRITER_FLUSH_CLOSE_BRACKET(xml_writer) \
- if((xml_writer->flags & XML_WRITER_AUTO_EMPTY) && \
+ if((xml_writer->flags & XML_WRITER_AUTO_EMPTY) && \
xml_writer->current_element && \
!(xml_writer->current_element->content_cdata_seen || \
xml_writer->current_element->content_element_seen)) { \
@@ -915,7 +915,7 @@ raptor_xml_writer_set_option_string(raptor_xml_writer *xml_writer,
if(raptor_option_value_is_numeric(option))
return raptor_xml_writer_set_option(xml_writer, option,
- atoi((const char*)value));
+ atoi((const char*)value));
return -1;
}