]> granicus.if.org Git - graphviz/commitdiff
sfio: make '_sftype' static
authorMatthew Fernandez <matthew.fernandez@gmail.com>
Sun, 14 Aug 2022 21:25:30 +0000 (14:25 -0700)
committerMatthew Fernandez <matthew.fernandez@gmail.com>
Sat, 20 Aug 2022 03:02:56 +0000 (20:02 -0700)
This function is not used outside of its containing file.

lib/sfio/sfhdr.h
lib/sfio/sfopen.c

index 0700a4f31194a8badb672ce36cbda395a5aaea60..79a9552718df72a752af1f83cb752033eca8763b 100644 (file)
@@ -545,7 +545,6 @@ extern "C" {
     extern int _sfpopen(Sfio_t *, int, int, int);
     extern int _sfpclose(Sfio_t *);
     extern int _sfmode(Sfio_t *, int, int);
-    extern int _sftype(const char *, int *, int *);
     extern int _sfexcept(Sfio_t *, int, ssize_t, Sfdisc_t *);
     extern Sfrsrv_t *_sfrsrv(Sfio_t *, ssize_t);
     extern int _sfsetpool(Sfio_t *);
index cda11e2ec4d581be7f40113f9f57fd22bcfa77e2..a8216148f51e6ea2a751c67b6c1e6191d907acc8 100644 (file)
@@ -19,6 +19,8 @@
 **     Written by Kiem-Phong Vo.
 */
 
+static int _sftype(const char *mode, int *oflagsp, int *uflagp);
+
 /**
  * @param file file/string to be opened
  * @param mode mode of the stream
@@ -83,8 +85,7 @@ Sfio_t *sfopen(const char *file, const char *mode)
     return f;
 }
 
-int _sftype(const char *mode, int *oflagsp, int *uflagp)
-{
+static int _sftype(const char *mode, int *oflagsp, int *uflagp) {
     int sflags, oflags, uflag;
 
     if (!mode)