summaryrefslogtreecommitdiff
path: root/utils/hp2ps/Utilities.c
diff options
context:
space:
mode:
authorIan Lynagh <igloo@earth.li>2011-08-01 01:07:12 +0100
committerIan Lynagh <igloo@earth.li>2011-08-01 01:07:12 +0100
commit96ebe2fa43b9ee98cd82d31760c57db0fea18495 (patch)
tree93e6995b75c08c84f2e7fc908ec3634cd64b0e92 /utils/hp2ps/Utilities.c
parentb4a01788a1a833de64cba041c796fa35e0275220 (diff)
downloadhaskell-96ebe2fa43b9ee98cd82d31760c57db0fea18495.tar.gz
Remove some antiquated C constructs
Fixes validate on amd64/Linux with: SRC_CC_OPTS += -Wmissing-parameter-type SRC_CC_OPTS += -Wold-style-declaration SRC_CC_OPTS += -Wold-style-definition
Diffstat (limited to 'utils/hp2ps/Utilities.c')
-rw-r--r--utils/hp2ps/Utilities.c26
1 files changed, 8 insertions, 18 deletions
diff --git a/utils/hp2ps/Utilities.c b/utils/hp2ps/Utilities.c
index c9fb612f0e..5139144d53 100644
--- a/utils/hp2ps/Utilities.c
+++ b/utils/hp2ps/Utilities.c
@@ -6,8 +6,7 @@
extern void* malloc();
char*
-Basename(name)
- char* name;
+Basename(char *name)
{
char* t;
@@ -24,8 +23,7 @@ Basename(name)
}
void
-DropSuffix(name, suffix)
- char* name; char* suffix;
+DropSuffix(char *name, char *suffix)
{
char* t;
@@ -44,8 +42,7 @@ DropSuffix(name, suffix)
}
FILE*
-OpenFile(s, mode)
- char* s; char* mode;
+OpenFile(char *s, char *mode)
{
FILE* r;
@@ -65,9 +62,7 @@ OpenFile(s, mode)
*/
void
-CommaPrint(fp,n)
- FILE* fp;
- intish n;
+CommaPrint(FILE *fp, intish n)
{
if (n < ONETHOUSAND) {
fprintf(fp, "%d", (int)n);
@@ -78,8 +73,7 @@ CommaPrint(fp,n)
}
void *
-xmalloc(n)
- size_t n;
+xmalloc(size_t n)
{
void *r;
@@ -92,9 +86,7 @@ xmalloc(n)
}
void *
-xrealloc(p, n)
- void *p;
- size_t n;
+xrealloc(void *p, size_t n)
{
void *r;
extern void *realloc();
@@ -108,8 +100,7 @@ xrealloc(p, n)
}
char *
-copystring(s)
- char *s;
+copystring(char *s)
{
char *r;
@@ -119,8 +110,7 @@ copystring(s)
}
char *
-copystring2(s, t)
- char *s, *t;
+copystring2(char *s, char *t)
{
char *r;