xc/programs/Xserver/Xprint/Util.c

xc/programs/Xserver/Xprint/attributes.c
xc/programs/Xserver/Xprint/attributes.h
//bugs.freedesktop.org/show_bug.cgi?id=2254) attachment #1654
    (https://bugs.freedesktop.org/attachment.cgi?id=1654) and attachment
    #1659 (https://bugs.freedesktop.org/attachment.cgi?id=1659) Fix for
    gcc4.0 build failure (including removing |ExecCommand()| - the function
    has no consumer and can safely be removed). Patch by Egbert Eich
    <eich@freedesktop.org> and Roland Mainz <roland.mainz@nrubsig.org>.
This commit is contained in:
Roland Mainz 2005-01-24 03:39:28 +00:00
parent 3211034b32
commit 05fbf7adc1
4 changed files with 0 additions and 58 deletions

View file

@ -141,30 +141,6 @@ ReplaceFileString(
return string;
}
/*
* ExecCommand takes two character pointers - the command to execute,
* and the "argv" style NULL-terminated vector of arguments for the command.
* We wait for the command to terminate before continuing to ensure that
* we don't delete the job file before the spooler has made a copy.
*/
void
ExecCommand(
char *pCommand,
char **argVector)
{
pid_t childPid;
int status;
if((childPid = fork()) == 0)
{
execv(pCommand, argVector);
}
else
{
(void) waitpid(childPid, &status, 0);
}
return;
}
/*
* TransferBytes reads numBytes of data from pSrcFile and writes them

View file

@ -1083,34 +1083,6 @@ XpSpoolerGetServerAttributes(void)
return db;
}
/*
* ExecuteCommand takes two pointers - the command to execute,
* and the "argv" style NULL-terminated vector of arguments for the command.
* We wait for the command to terminate before continuing to ensure that
* we don't delete the job file before the spooler has made a copy.
*/
static void
ExecCommand(pCommand, argVector)
char *pCommand;
char **argVector;
{
pid_t childPid;
int status;
if((childPid = fork()) == 0)
{
/* return BadAlloc? */
if (execv(pCommand, argVector) == -1) {
FatalError("unable to exec '%s'", pCommand);
}
}
else
{
(void) waitpid(childPid, &status, 0);
}
return;
}
/*
* SendFileToCommand takes three character pointers - the file name,
* the command to execute,

View file

@ -109,8 +109,6 @@ char *ReplaceAnyString(char *string,
char *ReplaceFileString(char *string,
char *inFileName,
char *outFileName);
void ExecCommand(char *pCommand,
char **argVector);
int TransferBytes(FILE *pSrcFile,
FILE *pDstFile,
int numBytes);

View file

@ -350,7 +350,6 @@ typedef struct
extern Bool InitializePsDriver(int ndx, ScreenPtr pScreen, int argc,
char **argv);
static Bool PsDestroyContext(XpContextPtr pCon);
extern XpContextPtr PsGetContextFromWindow(WindowPtr win);
/*
@ -374,9 +373,6 @@ extern int PsGetDocumentData(XpContextPtr pCon, ClientPtr client,
*/
extern Bool PsCreateGC(GCPtr pGC);
static int PsGetDrawablePrivateStuff(DrawablePtr pDrawable, GC *gc,
unsigned long *valid, PsOutPtr *psOut,
ColormapPtr *cMap);
extern PsContextPrivPtr PsGetPsContextPriv( DrawablePtr pDrawable );
extern int PsUpdateDrawableGC(GCPtr pGC, DrawablePtr pDrawable,
PsOutPtr *psOut, ColormapPtr *cMap);