diff options
author | Colin Walters <walters@verbum.org> | 2010-12-02 11:34:46 -0500 |
---|---|---|
committer | Colin Walters <walters@verbum.org> | 2010-12-03 16:03:32 -0500 |
commit | 0007b3ec76bafa732201ad96eccdf8b5626fe3fd (patch) | |
tree | c0208d5ce787e3099f5834742a533b31704783a8 /girepository/cmph/bdz.c | |
parent | 0b00fb76e3de40010b69ca64ab5fa5bf039e7478 (diff) | |
download | gobject-introspection-0007b3ec76bafa732201ad96eccdf8b5626fe3fd.tar.gz |
cmph: Squash a lot of gcc -Wall compiler warnings
* Functions taking no parameters need to explicitly say (void).
* Mark some functions as static that are
* Comment out an unused function in bdz.c
* Change loop indicies "i" to be unsigned if our limit is unsigned
Diffstat (limited to 'girepository/cmph/bdz.c')
-rwxr-xr-x | girepository/cmph/bdz.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/girepository/cmph/bdz.c b/girepository/cmph/bdz.c index f422c8f9..a57f70f8 100755 --- a/girepository/cmph/bdz.c +++ b/girepository/cmph/bdz.c @@ -107,7 +107,7 @@ static void bdz_add_edge(bdz_graph3_t * graph3, cmph_uint32 v0, cmph_uint32 v1, static void bdz_dump_graph(bdz_graph3_t* graph3, cmph_uint32 nedges, cmph_uint32 nvertices) { - int i; + cmph_uint32 i; for(i=0;i<nedges;i++){ printf("\nedge %d %d %d %d ",i,graph3->edges[i].vertices[0], graph3->edges[i].vertices[1],graph3->edges[i].vertices[2]); @@ -216,7 +216,7 @@ static void assigning(bdz_config_data_t *bdz, bdz_graph3_t* graph3, bdz_queue_t static void ranking(bdz_config_data_t *bdz); static cmph_uint32 rank(cmph_uint32 b, cmph_uint32 * ranktable, cmph_uint8 * g, cmph_uint32 vertex); -bdz_config_data_t *bdz_config_new() +bdz_config_data_t *bdz_config_new(void) { bdz_config_data_t *bdz; bdz = (bdz_config_data_t *)malloc(sizeof(bdz_config_data_t)); @@ -560,7 +560,8 @@ void bdz_load(FILE *f, cmph_t *mphf) } -cmph_uint32 bdz_search_ph(cmph_t *mphf, const char *key, cmph_uint32 keylen) +/* +static cmph_uint32 bdz_search_ph(cmph_t *mphf, const char *key, cmph_uint32 keylen) { bdz_data_t *bdz = mphf->data; cmph_uint32 hl[3]; @@ -572,6 +573,7 @@ cmph_uint32 bdz_search_ph(cmph_t *mphf, const char *key, cmph_uint32 keylen) vertex = hl[(GETVALUE(bdz->g, hl[0]) + GETVALUE(bdz->g, hl[1]) + GETVALUE(bdz->g, hl[2])) % 3]; return vertex; } +*/ static inline cmph_uint32 rank(cmph_uint32 b, cmph_uint32 * ranktable, cmph_uint8 * g, cmph_uint32 vertex) { |