groff-commit
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[groff] 01/01: src: Declare function protypes where necessary.


From: G. Branden Robinson
Subject: [groff] 01/01: src: Declare function protypes where necessary.
Date: Sat, 11 Nov 2017 11:48:36 -0500 (EST)

gbranden pushed a commit to branch master
in repository groff.

commit 4d44081267e72369241dbb83dc541810c0e76079
Author: G. Branden Robinson <address@hidden>
Date:   Sat Nov 11 11:47:16 2017 -0500

    src: Declare function protypes where necessary.
    
    Fix bug https://savannah.gnu.org/bugs/?51513.
    
    Signed-off-by: Bjarni Ingi Gislason <address@hidden>
    
    Moved protypes inside extern "C" if the function definitions were.
    
    Signed-off-by: G. Branden Robinson <address@hidden>
---
 ChangeLog                    | 6 ++++++
 src/libs/libbib/map.c        | 4 ++++
 src/libs/libgroff/iftoa.c    | 5 ++++-
 src/libs/libgroff/itoa.c     | 4 ++++
 src/libs/libgroff/quotearg.c | 4 ++++
 src/roff/groff/pipeline.c    | 3 +++
 src/utils/indxbib/signal.c   | 3 +++
 7 files changed, 28 insertions(+), 1 deletion(-)

diff --git a/ChangeLog b/ChangeLog
index 353ef77..ed95763 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,9 @@
+2017-11-11  Bjarni Ingi Gislason <address@hidden>
+
+       src: Declare function protypes where necessary.
+
+       Fix bug https://savannah.gnu.org/bugs/?51513.
+
 2017-11-10  Bjarni Ingi Gislason <address@hidden>
 
        mom: Abort early with diagnostic in compatibility mode.
diff --git a/src/libs/libbib/map.c b/src/libs/libbib/map.c
index 4825183..5d635af 100644
--- a/src/libs/libbib/map.c
+++ b/src/libs/libbib/map.c
@@ -36,6 +36,10 @@ along with this program.  If not, see 
<http://www.gnu.org/licenses/>. */
 extern "C" {
 #endif
 
+/* Prototypes */
+char *mapread(int, int);
+int unmap(char *, int);
+
 char *mapread(int fd, int nbytes)
 {
   char *p = (char *)mmap((void *)0, (size_t)nbytes, PROT_READ,
diff --git a/src/libs/libgroff/iftoa.c b/src/libs/libgroff/iftoa.c
index 26d6395..ffb7df4 100644
--- a/src/libs/libgroff/iftoa.c
+++ b/src/libs/libgroff/iftoa.c
@@ -22,10 +22,13 @@ along with this program.  If not, see 
<http://www.gnu.org/licenses/>. */
 extern "C" {
 #endif
 
+/* Prototype */
+char *if_to_a(int, int);
+
 char *if_to_a(int i, int decimal_point)
 {
   /* room for a -, INT_DIGITS digits, a decimal point, and a terminating '\0' 
*/
-  static char buf[INT_DIGITS + 3];                     
+  static char buf[INT_DIGITS + 3];
   char *p = buf + INT_DIGITS + 2;
   int point = 0;
   buf[INT_DIGITS + 2] = '\0';
diff --git a/src/libs/libgroff/itoa.c b/src/libs/libgroff/itoa.c
index c4f58c5..1d85f56 100644
--- a/src/libs/libgroff/itoa.c
+++ b/src/libs/libgroff/itoa.c
@@ -23,6 +23,10 @@ along with this program.  If not, see 
<http://www.gnu.org/licenses/>. */
 extern "C" {
 #endif
 
+/* Prototypes */
+char *i_to_a(int);
+char *ui_to_a(unsigned int);
+
 char *i_to_a(int i)
 {
   /* Room for INT_DIGITS digits, - and '\0' */
diff --git a/src/libs/libgroff/quotearg.c b/src/libs/libgroff/quotearg.c
index b620993..f0f65cb 100644
--- a/src/libs/libgroff/quotearg.c
+++ b/src/libs/libgroff/quotearg.c
@@ -43,6 +43,10 @@ along with this program.  If not, see 
<http://www.gnu.org/licenses/>. */
 
 extern char *program_name;     /* main program must define this */
 
+/* Prototypes */
+char *quote_arg(char *);
+void purge_quoted_args(char **);
+
 #undef FALSE
 #undef TRUE
 #define FALSE 0
diff --git a/src/roff/groff/pipeline.c b/src/roff/groff/pipeline.c
index a7b0876..ef47cb8 100644
--- a/src/roff/groff/pipeline.c
+++ b/src/roff/groff/pipeline.c
@@ -77,6 +77,9 @@ extern char *strerror();
 
 #define error c_error
 
+/* Prototype */
+int run_pipeline(int, char ***, int);
+
 #ifdef __cplusplus
 extern "C" {
 #endif
diff --git a/src/utils/indxbib/signal.c b/src/utils/indxbib/signal.c
index 432a82a..875b8c2 100644
--- a/src/utils/indxbib/signal.c
+++ b/src/utils/indxbib/signal.c
@@ -35,6 +35,9 @@ that is correct for C++, so we implement all signal handling 
in C. */
 extern "C" {
 #endif
 
+/* Prototype */
+void catch_fatal_signals(void);
+
 extern void cleanup(void);
 
 static RETSIGTYPE handle_fatal_signal(int signum)



reply via email to

[Prev in Thread] Current Thread [Next in Thread]