diff options
author | Mattias Andrée <maandree@operamail.com> | 2014-08-24 00:46:58 +0200 |
---|---|---|
committer | Mattias Andrée <maandree@operamail.com> | 2014-08-24 00:46:58 +0200 |
commit | c217ab36a03a9d00a790af3963d3041bf03e6985 (patch) | |
tree | f190ac27ad68b24bb49530e76bdaa1607b97b521 /src/libmdsserver | |
parent | update todo (diff) | |
download | mds-c217ab36a03a9d00a790af3963d3041bf03e6985.tar.gz mds-c217ab36a03a9d00a790af3963d3041bf03e6985.tar.bz2 mds-c217ab36a03a9d00a790af3963d3041bf03e6985.tar.xz |
m + do not any assumtion of int typedefs
Signed-off-by: Mattias Andrée <maandree@operamail.com>
Diffstat (limited to 'src/libmdsserver')
-rw-r--r-- | src/libmdsserver/config.h | 2 | ||||
-rw-r--r-- | src/libmdsserver/linked-list.c | 20 | ||||
-rw-r--r-- | src/libmdsserver/linked-list.h | 2 |
3 files changed, 12 insertions, 12 deletions
diff --git a/src/libmdsserver/config.h b/src/libmdsserver/config.h index 4cc4fc3..dbd7655 100644 --- a/src/libmdsserver/config.h +++ b/src/libmdsserver/config.h @@ -153,7 +153,7 @@ * Pattern for the names of shared object to which states are marshalled */ #ifndef SHM_PATH_PATTERN -#define SHM_PATH_PATTERN "/.proc-pid-%lu" +#define SHM_PATH_PATTERN "/.proc-pid-%ji" #endif diff --git a/src/libmdsserver/linked-list.c b/src/libmdsserver/linked-list.c index 066414a..948b0a8 100644 --- a/src/libmdsserver/linked-list.c +++ b/src/libmdsserver/linked-list.c @@ -476,31 +476,31 @@ int linked_list_unmarshal(linked_list_t* restrict this, char* restrict data) * @param this The list * @param output Output file */ -void linked_list_dump(linked_list_t* restrict this, FILE* output) +void linked_list_dump(linked_list_t* restrict this, FILE* restrict output) { ssize_t i; size_t j; fprintf(output, "======= LINKED LIST DUMP =======\n"); - fprintf(output, "Capacity: %lu\n", this->capacity); - fprintf(output, "End: %lu\n", this->end); - fprintf(output, "Reuse head: %lu\n", this->reuse_head); - fprintf(output, "Edge: %li\n", this->edge); + fprintf(output, "Capacity: %zu\n", this->capacity); + fprintf(output, "End: %zu\n", this->end); + fprintf(output, "Reuse head: %zu\n", this->reuse_head); + fprintf(output, "Edge: %zi\n", this->edge); fprintf(output, "--------------------------------\n"); fprintf(output, "Node table (Next, Prev, Value):\n"); i = this->edge; - fprintf(output, " %li: %li, %li, %lu\n", i, this->next[i], this->previous[i], this->values[i]); + fprintf(output, " %zi: %zi, %zi, %zu\n", i, this->next[i], this->previous[i], this->values[i]); foreach_linked_list_node((*this), i) - fprintf(output, " %li: %li, %li, %lu\n", i, this->next[i], this->previous[i], this->values[i]); + fprintf(output, " %zi: %zi, %zi, %zu\n", i, this->next[i], this->previous[i], this->values[i]); i = this->edge; - fprintf(output, " %li: %li, %li, %lu\n", i, this->next[i], this->previous[i], this->values[i]); + fprintf(output, " %zi: %zi, %zi, %zu\n", i, this->next[i], this->previous[i], this->values[i]); fprintf(output, "--------------------------------\n"); fprintf(output, "Raw node table:\n"); for (j = 0; j < this->end; j++) - fprintf(output, " %lu: %li, %li, %lu\n", i, this->next[i], this->previous[i], this->values[i]); + fprintf(output, " %zu: %zi, %zi, %zu\n", i, this->next[i], this->previous[i], this->values[i]); fprintf(output, "--------------------------------\n"); fprintf(output, "Reuse stack:\n"); for (j = 0; j < this->reuse_head; j++) - fprintf(output, " %lu: %li\n", j, this->reusable[j]); + fprintf(output, " %zu: %zi\n", j, this->reusable[j]); fprintf(output, "================================\n"); } diff --git a/src/libmdsserver/linked-list.h b/src/libmdsserver/linked-list.h index e77f33d..4edaad2 100644 --- a/src/libmdsserver/linked-list.h +++ b/src/libmdsserver/linked-list.h @@ -282,7 +282,7 @@ int linked_list_unmarshal(linked_list_t* restrict this, char* restrict data); * @param this The list * @param output Output file */ -void linked_list_dump(linked_list_t* restrict this, FILE* output); +void linked_list_dump(linked_list_t* restrict this, FILE* restrict output); #endif |