diff options
author | David Robillard <d@drobilla.net> | 2012-08-09 00:01:07 +0000 |
---|---|---|
committer | David Robillard <d@drobilla.net> | 2012-08-09 00:01:07 +0000 |
commit | a4be30c59cd6452ab595d221bc4e97bab00517a7 (patch) | |
tree | 1bd6d196e8236dca2dfa993dbc356869d718025b /src/sord_validate.c | |
parent | fcaa07ca53ae5a4e586117fa72bd92de903affef (diff) | |
download | sord-a4be30c59cd6452ab595d221bc4e97bab00517a7.tar.gz sord-a4be30c59cd6452ab595d221bc4e97bab00517a7.tar.bz2 sord-a4be30c59cd6452ab595d221bc4e97bab00517a7.zip |
Fix warnings: -Wshadow -Wpointer-arith -Wcast-align -Wstrict-prototypes -Wmissing-prototypes.
git-svn-id: http://svn.drobilla.net/sord/trunk@244 3d64ff67-21c5-427c-a301-fe4f08042e5a
Diffstat (limited to 'src/sord_validate.c')
-rw-r--r-- | src/sord_validate.c | 24 |
1 files changed, 12 insertions, 12 deletions
diff --git a/src/sord_validate.c b/src/sord_validate.c index 8ced620..cb87878 100644 --- a/src/sord_validate.c +++ b/src/sord_validate.c @@ -66,8 +66,8 @@ typedef struct { int n_errors = 0; bool one_line_errors = false; -int -print_version() +static int +print_version(void) { printf("sord_validate " SORD_VERSION " <http://drobilla.net/software/sord>\n"); @@ -78,7 +78,7 @@ print_version() return 0; } -int +static int print_usage(const char* name, bool error) { FILE* const os = error ? stderr : stdout; @@ -94,7 +94,7 @@ print_usage(const char* name, bool error) return error ? 1 : 0; } -uint8_t* +static uint8_t* absolute_path(const uint8_t* path) { #ifdef _WIN32 @@ -106,7 +106,7 @@ absolute_path(const uint8_t* path) #endif } -void +static void error(const char* msg, const SordQuad quad) { const char* sep = one_line_errors ? "\t" : "\n "; @@ -118,7 +118,7 @@ error(const char* msg, const SordQuad quad) sep, (const char*)sord_node_get_string(quad[SORD_OBJECT])); } -bool +static bool is_subclass_of(SordModel* model, const URIs* uris, const SordNode* klass, @@ -147,16 +147,16 @@ is_subclass_of(SordModel* model, return false; } -bool +static bool regexp_match(const char* pat, const char* str) { #ifdef HAVE_PCRE - const char* error; + const char* err; int erroffset; - pcre* re = pcre_compile(pat, PCRE_ANCHORED, &error, &erroffset, NULL); + pcre* re = pcre_compile(pat, PCRE_ANCHORED, &err, &erroffset, NULL); if (!re) { fprintf(stderr, "Error in regexp \"%s\" at offset %d (%s)\n", - pat, erroffset, error); + pat, erroffset, err); return false; } @@ -169,7 +169,7 @@ regexp_match(const char* pat, const char* str) return true; } -bool +static bool literal_is_valid(SordModel* model, const URIs* uris, const SordNode* literal, @@ -197,7 +197,7 @@ literal_is_valid(SordModel* model, return false; } -bool +static bool check_type(SordModel* model, URIs* uris, const SordNode* node, |