|
From: <and...@us...> - 2013-12-09 14:35:47
|
Revision: 12831
http://sourceforge.net/p/plplot/code/12831
Author: andrewross
Date: 2013-12-09 14:35:42 +0000 (Mon, 09 Dec 2013)
Log Message:
-----------
Fix up const arguments to pl_create_tempfifo. Fixes compiler warning.
Modified Paths:
--------------
trunk/drivers/tk.c
trunk/include/plplotP.h
trunk/src/plstdio.c
Modified: trunk/drivers/tk.c
===================================================================
--- trunk/drivers/tk.c 2013-12-09 14:12:01 UTC (rev 12830)
+++ trunk/drivers/tk.c 2013-12-09 14:35:42 UTC (rev 12831)
@@ -1521,7 +1521,7 @@
TkDev *dev = (TkDev *) pls->dev;
PLiodev *iodev = (PLiodev *) dev->iodev;
size_t bufmax = (size_t) ( pls->bufmax * 1.2 );
- char *dirname = NULL;
+ const char *dirname = NULL;
dbug_enter( "link_init" );
@@ -1532,7 +1532,7 @@
// This uses the pl_create_tempfifo function to create
// the fifo in a safe manner by first creating a private
// temporary directory.
- iodev->fileName = pl_create_tempfifo( (char **) &iodev->fileName, &dirname );
+ iodev->fileName = pl_create_tempfifo( (const char **) &iodev->fileName, &dirname );
if ( dirname == NULL || iodev->fileName == NULL )
abort_session( pls, "mkfifo error" );
Modified: trunk/include/plplotP.h
===================================================================
--- trunk/include/plplotP.h 2013-12-09 14:12:01 UTC (rev 12830)
+++ trunk/include/plplotP.h 2013-12-09 14:35:42 UTC (rev 12831)
@@ -1229,7 +1229,7 @@
// Create a temporary fifo securely
PLDLLIMPEXP char *
-pl_create_tempfifo( char **p_fifoname, char **p_dirname );
+pl_create_tempfifo( const char **p_fifoname, const char **p_dirname );
#ifdef __cplusplus
}
Modified: trunk/src/plstdio.c
===================================================================
--- trunk/src/plstdio.c 2013-12-09 14:12:01 UTC (rev 12830)
+++ trunk/src/plstdio.c 2013-12-09 14:35:42 UTC (rev 12831)
@@ -271,7 +271,7 @@
// The function returns the file name of the fifo.
//
char *
-pl_create_tempfifo( char **p_fifoname, char **p_dirname )
+pl_create_tempfifo( const char **p_fifoname, const char **p_dirname )
{
#if !defined PL_HAVE_MKDTEMP || !defined PL_HAVE_MKFIFO
plwarn( "Creating fifos not supported on this platform" );
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|