diff --git a/src/util/secsave.c b/src/util/secsave.c index 4523f7cca..03e729167 100644 --- a/src/util/secsave.c +++ b/src/util/secsave.c @@ -65,7 +65,7 @@ /* FIXME: locking system on files about to be rewritten ? */ /* FIXME: Low risk race conditions about ssi->file_name. */ -enum secsave_errno secsave_errno = SS_ERR_NONE; +secsave_errno_T secsave_errno = SS_ERR_NONE; /** Open a file for writing in a secure way. @returns a pointer to a @@ -360,7 +360,7 @@ secure_fprintf(struct secure_save_info *ssi, const char *format, ...) } char * -secsave_strerror(enum secsave_errno secsave_error, struct terminal *term) +secsave_strerror(secsave_errno_T secsave_error, struct terminal *term) { switch (secsave_error) { case SS_ERR_OPEN_READ: diff --git a/src/util/secsave.h b/src/util/secsave.h index 248ec2214..4eb1b6d61 100644 --- a/src/util/secsave.h +++ b/src/util/secsave.h @@ -28,7 +28,9 @@ enum secsave_errno { SS_ERR_OTHER, }; -extern enum secsave_errno secsave_errno; /**< internal secsave error number */ +typedef int secsave_errno_T; + +extern secsave_errno_T secsave_errno; /**< internal secsave error number */ struct secure_save_info { FILE *fp; /**< file stream pointer */ @@ -47,7 +49,7 @@ int secure_fputc(struct secure_save_info *, int); int secure_fprintf(struct secure_save_info *, const char *, ...); -char *secsave_strerror(enum secsave_errno, struct terminal *); +char *secsave_strerror(secsave_errno_T, struct terminal *); #ifdef __cplusplus }