Remove superfluous trailing white space from C files

This commit is contained in:
Douglas Clowes
2014-05-16 15:48:41 +10:00
parent 1881907e00
commit 4c65f82116
91 changed files with 1313 additions and 1313 deletions

View File

@@ -1,10 +1,10 @@
/*--------------------------------------------------------------------------
I T C 4 D R I V
This file contains the implementation of a driver for the Oxford
This file contains the implementation of a driver for the Oxford
Instruments ITC4 Temperature controller.
Mark Koennecke, Juli 1997
Copyright:
@@ -49,7 +49,7 @@
typedef struct __EVDriver *pEVDriver;
#include <evdriver.i>
#include <evdriver.i>
/* Do we need these ?
#include <sics.h>
#include <modriv.h>
@@ -64,8 +64,8 @@
pEVDriver CreateITC4Driver(int argc, char *argv[]);
int ConfigITC4(pEVDriver self);
/*-----------------------------------------------------------------------*/
typedef struct {
pITC4 pData;
@@ -84,12 +84,12 @@
{
pITC4Driv pMe = NULL;
int iRet;
assert(self);
pMe = (pITC4Driv)self->pPrivate;
assert(pMe);
iRet = ITC4_Read(&pMe->pData,fPos);
iRet = ITC4_Read(&pMe->pData,fPos);
if(iRet != 1 )
{
pMe->iLastError = iRet;
@@ -102,13 +102,13 @@
return 0;
}
return 1;
}
}
/*----------------------------------------------------------------------------*/
static int ITC4Run(pEVDriver self, float fVal)
{
pITC4Driv pMe = NULL;
int iRet;
assert(self);
pMe = (pITC4Driv )self->pPrivate;
assert(pMe);
@@ -125,7 +125,7 @@
static int ITC4Error(pEVDriver self, int *iCode, char *error, int iErrLen)
{
pITC4Driv pMe = NULL;
assert(self);
pMe = (pITC4Driv)self->pPrivate;
assert(pMe);
@@ -137,7 +137,7 @@
}
else
{
ITC4_ErrorTxt(&pMe->pData,pMe->iLastError,error,iErrLen);
ITC4_ErrorTxt(&pMe->pData,pMe->iLastError,error,iErrLen);
}
return 1;
}
@@ -146,7 +146,7 @@
{
pITC4Driv pMe = NULL;
int iRet;
assert(self);
pMe = (pITC4Driv )self->pPrivate;
assert(pMe);
@@ -159,13 +159,13 @@
}
return 1;
}
}
/*--------------------------------------------------------------------------*/
static int ITC4Init(pEVDriver self)
{
pITC4Driv pMe = NULL;
int iRet;
assert(self);
pMe = (pITC4Driv )self->pPrivate;
assert(pMe);
@@ -182,29 +182,29 @@
{
pMe->iLastError = iRet;
return 0;
}
}
}
return 1;
}
}
/*--------------------------------------------------------------------------*/
static int ITC4Close(pEVDriver self)
{
pITC4Driv pMe = NULL;
int iRet;
assert(self);
pMe = (pITC4Driv )self->pPrivate;
assert(pMe);
ITC4_Close(&pMe->pData);
return 1;
}
}
/*---------------------------------------------------------------------------*/
static int ITC4Fix(pEVDriver self, int iError)
{
pITC4Driv pMe = NULL;
int iRet;
assert(self);
pMe = (pITC4Driv )self->pPrivate;
assert(pMe);
@@ -230,11 +230,11 @@
if(iRet)
{
return DEVREDO;
}
}
else
{
return DEVFAULT;
}
}
break;
/* handable protocoll errors */
case EL734__BAD_TMO:
@@ -243,47 +243,47 @@
case -501: /* Bad_COM */
return DEVREDO;
case -504: /* Badly formatted */
return DEVREDO;
return DEVREDO;
default:
return DEVFAULT;
break;
break;
}
return DEVFAULT;
}
/*--------------------------------------------------------------------------*/
static int ITC4Halt(pEVDriver *self)
{
assert(self);
return 1;
}
/*------------------------------------------------------------------------*/
void KillITC4(void *pData)
{
pITC4Driv pMe = NULL;
pMe = (pITC4Driv)pData;
assert(pMe);
if(pMe->pHost)
{
free(pMe->pHost);
}
free(pMe);
}
}
/*------------------------------------------------------------------------*/
pEVDriver CreateITC4Driver(int argc, char *argv[])
{
pEVDriver pNew = NULL;
pITC4Driv pSim = NULL;
/* check for arguments */
if(argc < 3)
{
return NULL;
}
pNew = CreateEVDriver(argc,argv);
pSim = (pITC4Driv)malloc(sizeof(ITC4Driv));
memset(pSim,0,sizeof(ITC4Driv));
@@ -293,7 +293,7 @@
}
pNew->pPrivate = pSim;
pNew->KillPrivate = KillITC4;
/* initalise pITC4Driver */
pSim->iControl = atoi(argv[2]);
pSim->iRead = atoi(argv[1]);
@@ -304,8 +304,8 @@
pSim->pHost = strdup(argv[0]);
pSim->iPort = 0;
pSim->iChannel = 0;
/* initialise function pointers */
pNew->SetValue = ITC4Run;
pNew->GetValue = GetITC4Pos;
@@ -314,20 +314,20 @@
pNew->TryFixIt = ITC4Fix;
pNew->Init = ITC4Init;
pNew->Close = ITC4Close;
return pNew;
}
return pNew;
}
/*--------------------------------------------------------------------------*/
int ConfigITC4(pEVDriver self)
{
pITC4Driv pMe = NULL;
int iRet;
assert(self);
pMe = (pITC4Driv )self->pPrivate;
assert(pMe);
iRet = ITC4_Config(&pMe->pData, pMe->iTmo, pMe->iRead,
iRet = ITC4_Config(&pMe->pData, pMe->iTmo, pMe->iRead,
pMe->iControl,pMe->fDiv,pMe->fMult);
if(iRet < 0)
{
@@ -341,7 +341,7 @@
{
pITC4Driv pMe = NULL;
int iRet;
assert(self);
pMe = (pITC4Driv )self->pPrivate;
assert(pMe);
@@ -349,7 +349,7 @@
if( (iSensor < 1) || (iSensor > 4) )
{
return 0;
}
}
pMe->iRead = iSensor;
pMe->pData->iRead = iSensor;
return 1;
@@ -359,7 +359,7 @@
{
pITC4Driv pMe = NULL;
int iRet;
assert(self);
pMe = (pITC4Driv )self->pPrivate;
assert(pMe);
@@ -367,7 +367,7 @@
if( (iSensor < 1) || (iSensor > 4) )
{
return 0;
}
}
pMe->iControl = iSensor;
pMe->pData->iControl = iSensor;
return 1;
@@ -377,7 +377,7 @@
{
pITC4Driv pMe = NULL;
int iRet;
assert(self);
pMe = (pITC4Driv )self->pPrivate;
assert(pMe);
@@ -385,7 +385,7 @@
if(iSensor < 10)
{
return 0;
}
}
pMe->iTmo = iSensor;
return 1;
}
@@ -394,7 +394,7 @@
{
pITC4Driv pMe = NULL;
int iRet;
assert(self);
pMe = (pITC4Driv )self->pPrivate;
assert(pMe);
@@ -406,7 +406,7 @@
{
pITC4Driv pMe = NULL;
int iRet;
assert(self);
pMe = (pITC4Driv )self->pPrivate;
assert(pMe);
@@ -418,7 +418,7 @@
{
pITC4Driv pMe = NULL;
int iRet;
assert(self);
pMe = (pITC4Driv )self->pPrivate;
assert(pMe);
@@ -430,7 +430,7 @@
{
pITC4Driv pMe = NULL;
int iRet;
assert(self);
pMe = (pITC4Driv )self->pPrivate;
assert(pMe);
@@ -442,7 +442,7 @@
{
pITC4Driv pMe = NULL;
int iRet;
assert(self);
pMe = (pITC4Driv )self->pPrivate;
assert(pMe);
@@ -455,7 +455,7 @@
{
pITC4Driv pMe = NULL;
int iRet;
assert(self);
pMe = (pITC4Driv )self->pPrivate;
assert(pMe);
@@ -467,7 +467,7 @@
{
pITC4Driv pMe = NULL;
int iRet;
assert(self);
pMe = (pITC4Driv )self->pPrivate;
assert(pMe);
@@ -475,4 +475,4 @@
pMe->fMult = fDiv;
return 1;
}