enable trim_trailing_whitespace

This commit is contained in:
zimoch authored and Andrew Johnson committed 2026-02-18 10:34:08 -06:00
1 parent cd36c03da4
commit db693d4930
99 files changed
+515 -513

No files matched your search

+1 -1
View File
@@ -310,7 +310,7 @@ typedef struct chFilterIf {
} chFilterIf;
/** \brief Filter plugin data
*
*
* A chFilterPlugin object holds data about a filter plugin.
*/
typedef struct chFilterPlugin {
+1 -1
View File
@@ -1217,7 +1217,7 @@ static long cvt_f_st(const void *f, void *t, const dbAddr *paddr)
{
const epicsFloat32 *from = (const epicsFloat32 *) f;
char *to = (char *) t;
rset *prset = 0;
long status = 0;
long precision = 6;
+1 -1
View File
@@ -145,7 +145,7 @@ static void printFieldsList(DBENTRY *pdbentry, char** papfields, int nfields)
printf(", \"%s\"", (pvalue ? pvalue : ""));
}
printf("\n");
}
}
long dbl(const char *precordTypename, const char *fields)
{
@@ -77,7 +77,7 @@ static const iocshArg * const dbDumpFieldArgs[] =
static const iocshFuncDef dbDumpFieldFuncDef = {"dbDumpField",3,dbDumpFieldArgs,
"Dump information about the fieldName in the recordTypeName.\n"
"Example: dbDumpField pdbbase calcout A\n"
"If last argument(s) are missing, dump information\n"
"If last argument(s) are missing, dump information\n"
"about all fieldName in all recordTypeName in the database.\n"};
static void dbDumpFieldCallFunc(const iocshArgBuf *args)
{
@@ -36,7 +36,7 @@ static void iocBuildCallFunc(const iocshArgBuf *args)
}
/* iocRun */
static const iocshFuncDef iocRunFuncDef = {"iocRun",0,NULL,
static const iocshFuncDef iocRunFuncDef = {"iocRun",0,NULL,
"Bring the IOC out of its initial quiescent state to the running state.\n"
"See more: iocBuild, iocPause\n"};
static void iocRunCallFunc(const iocshArgBuf *args)
@@ -85,7 +85,7 @@ static const iocshArg * const systemArgs[] = {&systemArg0};
static const iocshFuncDef systemFuncDef = {"system",1,systemArgs,
"Send command string to the system command interpreter for execution.\n"
"Not available on all OSs.\n"
"To enable this command, add registrar(iocshSystemCommand) to an application dbd file,\n"
"To enable this command, add registrar(iocshSystemCommand) to an application dbd file,\n"
"or include system.dbd\n"};
static void systemCallFunc(const iocshArgBuf *args)
{
+2 -2
View File
@@ -96,7 +96,7 @@ static long init_record(struct dbCommon *pcommon, int pass)
recGblInitSimm(pcommon, &prec->sscn, &prec->oldsimm, &prec->simm, &prec->siml);
recGblInitConstantLink(&prec->siol, DBF_STRING, &prec->sval);
if( (pdset=(eventdset *)(prec->dset)) && (pdset->common.init_record) )
if( (pdset=(eventdset *)(prec->dset)) && (pdset->common.init_record) )
status=(*pdset->common.init_record)(pcommon);
prec->epvt = eventNameToHandle(prec->val);
@@ -111,7 +111,7 @@ static long process(struct dbCommon *pcommon)
long status=0;
unsigned char pact=prec->pact;
if((pdset!=NULL) && (pdset->common.number >= 5) && pdset->read_event )
if((pdset!=NULL) && (pdset->common.number >= 5) && pdset->read_event )
status=readValue(prec); /* read the new value */
/* check if device support set pact */
if ( !pact && prec->pact ) return(0);
+4 -4
View File
@@ -125,7 +125,7 @@ static long init_record(struct dbCommon *pcommon, int pass)
prec->lalm = prec->val;
prec->pval = prec->val;
prec->outpvt = EXEC_OUTPUT;
return 0;
}
@@ -450,14 +450,14 @@ static long conditional_write(longoutRecord *prec)
long status = 0;
int doDevSupWrite = 0;
switch (prec->oopt)
switch (prec->oopt)
{
case longoutOOPT_On_Change:
/* Forces a write op if a change in the OUT field is detected OR is first process */
if (prec->outpvt == EXEC_OUTPUT) {
doDevSupWrite = 1;
} else {
/* Only write if value is different from the previous one */
/* Only write if value is different from the previous one */
doDevSupWrite = (prec->val != prec->pval);
}
break;
@@ -479,7 +479,7 @@ static long conditional_write(longoutRecord *prec)
break;
case longoutOOPT_Transition_To_Non_zero:
doDevSupWrite = ((prec->val != 0)&&(prec->pval == 0));
doDevSupWrite = ((prec->val != 0)&&(prec->pval == 0));
break;
default:
+13 -13
View File
@@ -65,14 +65,14 @@ static void test_operator_display(void){
testdbPutFieldOk("test_ai_rec.HOPR", DBF_SHORT, hopr);
testdbPutFieldOk("test_ai_rec.LOPR", DBF_SHORT, lopr);
testdbPutFieldOk("test_ai_rec.PREC", DBF_SHORT, prec);
/* verify operator display parameters read back */
testdbGetFieldEqual("test_ai_rec.NAME", DBF_STRING, "test_ai_rec");
testdbGetFieldEqual("test_ai_rec.EGU", DBF_STRING, egu);
testdbGetFieldEqual("test_ai_rec.EGU", DBF_STRING, egu);
testdbGetFieldEqual("test_ai_rec.DESC", DBF_STRING, desc);
testdbGetFieldEqual("test_ai_rec.HOPR", DBF_SHORT, hopr);
testdbGetFieldEqual("test_ai_rec.LOPR", DBF_SHORT, lopr);
testdbGetFieldEqual("test_ai_rec.PREC", DBF_SHORT, prec);
testdbGetFieldEqual("test_ai_rec.PREC", DBF_SHORT, prec);
// number of tests = 7
}
@@ -96,7 +96,7 @@ static void test_no_linr_unit_conversion(void){
testdbPutFieldOk("test_ai_rec.ASLO", DBF_SHORT, aslo);
testdbPutFieldOk("test_ai_rec.AOFF", DBF_SHORT, aoff);
testdbPutFieldOk("test_ai_rec.LINR", DBF_LONG, menuConvertNO_CONVERSION);
/* verify conversion */
testdbPutFieldOk("test_ai_link_rec.VAL", DBF_SHORT, rval);
testdbGetFieldEqual("test_ai_rec.VAL", DBF_SHORT, val);
@@ -128,7 +128,7 @@ static void test_slope_linr_unit_conversion(void){
testdbPutFieldOk("test_ai_rec.ESLO", DBF_LONG, eslo);
testdbPutFieldOk("test_ai_rec.EOFF", DBF_LONG, eoff);
testdbPutFieldOk("test_ai_rec.LINR", DBF_LONG, menuConvertSLOPE);
/* verify conversion */
testdbPutFieldOk("test_ai_link_rec.VAL", DBF_LONG, rval);
testdbGetFieldEqual("test_ai_rec.VAL", DBF_LONG, val);
@@ -166,7 +166,7 @@ static void test_linear_linr_unit_conversion(void){
testdbPutFieldOk("test_ai_rec.EGUL", DBF_LONG, egul);
testdbPutFieldOk("test_ai_rec.EGUF", DBF_LONG, eguf);
testdbPutFieldOk("test_ai_rec.LINR", DBF_LONG, menuConvertLINEAR);
/* verify conversion */
testdbPutFieldOk("test_ai_link_rec.VAL", DBF_LONG, rval);
testdbGetFieldEqual("test_ai_rec.VAL", DBF_LONG, val);
@@ -249,7 +249,7 @@ static void test_smoothing_filter(void){
/* set well known starting point (without smmothing) */
testdbPutFieldOk("test_ai_link_rec.VAL", DBF_SHORT, rval1);
testdbGetFieldEqual("test_ai_rec.VAL", DBF_SHORT, val1);
/* set SMOO */
testdbPutFieldOk("test_ai_rec.SMOO", DBF_DOUBLE, smoo);
@@ -365,7 +365,7 @@ static void test_aftc(void){
/* test AFTC using a monitor and time stamps */
testdbPutFieldOk("test_ai_rec3.AFTC", DBF_DOUBLE, aftc);
testdbPutFieldOk("test_ai_rec3.SCAN", DBF_SHORT, menuScan_1_second);
/* set HIHI alarm VAL */
testdbPutFieldOk("test_ai_link_rec3.VAL", DBF_DOUBLE, 7550.0);
@@ -397,11 +397,11 @@ static void test_aftc(void){
/* Verify that alarm status is now MINOR */
testdbGetFieldEqual("test_ai_rec3.SEVR", DBF_SHORT, menuAlarmSevrMINOR);
/* Verify that time is at least equal to configured aftc */
diffTime = epicsTimeDiffInSeconds(&endTime, &startTime);
testOk(diffTime >= aftc, "ATFC time %lf", diffTime);
// number of tests = 18
}
@@ -416,12 +416,12 @@ MAIN(aiTest) {
testPlan(6+6+11+10+12+14+18+15+6+29+18);
testdbPrepare();
testdbPrepare();
testdbReadDatabase("recTestIoc.dbd", NULL, NULL);
recTestIoc_registerRecordDeviceDriver(pdbbase);
testdbReadDatabase("aiTest.db", NULL, NULL);
eltc(0);
testIocInitOk();
eltc(1);
@@ -436,7 +436,7 @@ MAIN(aiTest) {
test_smoothing_filter();
test_udf();
test_alarm();
test_aftc();
test_aftc();
testIocShutdownOk();
testdbCleanup();
+8 -8
View File
@@ -51,16 +51,16 @@ static void test_operator_display(void){
testdbPutFieldOk("test_bi_rec.DESC", DBF_STRING, "DESC_TEST");
/* verify operator display parameters */
testdbGetFieldEqual("test_bi_rec.ZNAM", DBF_STRING, "ZNAM_TEST");
testdbGetFieldEqual("test_bi_rec.ONAM", DBF_STRING, "ONAM_TEST");
testdbGetFieldEqual("test_bi_rec.ZNAM", DBF_STRING, "ZNAM_TEST");
testdbGetFieldEqual("test_bi_rec.ONAM", DBF_STRING, "ONAM_TEST");
testdbGetFieldEqual("test_bi_rec.NAME", DBF_STRING, "test_bi_rec");
testdbGetFieldEqual("test_bi_rec.DESC", DBF_STRING, "DESC_TEST");
/* verify conversion */
testdbPutFieldOk("test_bi_link_rec.VAL", DBF_SHORT, TRUE);
testdbGetFieldEqual("test_bi_rec.VAL", DBF_STRING, "ONAM_TEST");
testdbGetFieldEqual("test_bi_rec.VAL", DBF_STRING, "ONAM_TEST");
testdbPutFieldOk("test_bi_link_rec.VAL", DBF_SHORT, FALSE);
testdbGetFieldEqual("test_bi_rec.VAL", DBF_STRING, "ZNAM_TEST");
testdbGetFieldEqual("test_bi_rec.VAL", DBF_STRING, "ZNAM_TEST");
// number of tests = 11
}
@@ -78,7 +78,7 @@ static void test_alarm(void){
testdbPutFieldOk("test_bi_rec.ZSV", DBF_SHORT, menuAlarmSevrNO_ALARM);
testdbPutFieldOk("test_bi_rec.OSV", DBF_SHORT, menuAlarmSevrMINOR);
testdbPutFieldOk("test_bi_rec.COSV", DBF_SHORT, menuAlarmSevrINVALID);
/* verify alarm status is NO_ALARM*/
testdbGetFieldEqual("test_bi_rec.SEVR", DBF_SHORT, menuAlarmSevrNO_ALARM);
@@ -92,7 +92,7 @@ static void test_alarm(void){
/* verify LAML */
testdbGetFieldEqual("test_bi_rec.LALM", DBF_SHORT, TRUE);
// number of tests = 13
}
@@ -100,12 +100,12 @@ MAIN(biTest) {
testPlan(6+6+11+13);
testdbPrepare();
testdbPrepare();
testdbReadDatabase("recTestIoc.dbd", NULL, NULL);
recTestIoc_registerRecordDeviceDriver(pdbbase);
testdbReadDatabase("biTest.db", NULL, NULL);
eltc(0);
testIocInitOk();
eltc(1);
+7 -7
View File
@@ -76,16 +76,16 @@ static void test_operator_display(void){
testdbPutFieldOk("test_bo_rec.DESC", DBF_STRING, "DESC_TEST");
/* verify operator display parameters */
testdbGetFieldEqual("test_bo_rec.ZNAM", DBF_STRING, "ZNAM_TEST");
testdbGetFieldEqual("test_bo_rec.ONAM", DBF_STRING, "ONAM_TEST");
testdbGetFieldEqual("test_bo_rec.ZNAM", DBF_STRING, "ZNAM_TEST");
testdbGetFieldEqual("test_bo_rec.ONAM", DBF_STRING, "ONAM_TEST");
testdbGetFieldEqual("test_bo_rec.NAME", DBF_STRING, "test_bo_rec");
testdbGetFieldEqual("test_bo_rec.DESC", DBF_STRING, "DESC_TEST");
/* verify conversion */
testdbPutFieldOk("test_bo_rec.VAL", DBF_SHORT, TRUE);
testdbGetFieldEqual("test_bo_rec.VAL", DBF_STRING, "ONAM_TEST");
testdbGetFieldEqual("test_bo_rec.VAL", DBF_STRING, "ONAM_TEST");
testdbPutFieldOk("test_bo_rec.VAL", DBF_SHORT, FALSE);
testdbGetFieldEqual("test_bo_rec.VAL", DBF_STRING, "ZNAM_TEST");
testdbGetFieldEqual("test_bo_rec.VAL", DBF_STRING, "ZNAM_TEST");
// number of tests = 11
}
@@ -104,7 +104,7 @@ static void test_alarm(void){
testdbPutFieldOk("test_bo_rec.COSV", DBF_SHORT, menuAlarmSevrINVALID);
testdbPutFieldOk("test_bo_rec.IVOA", DBF_SHORT, menuIvoaSet_output_to_IVOV);
testdbPutFieldOk("test_bo_rec.IVOV", DBF_SHORT, FALSE);
/* Verify alarm status is NO_ALARM*/
testdbGetFieldEqual("test_bo_rec.SEVR", DBF_SHORT, menuAlarmSevrNO_ALARM);
@@ -136,12 +136,12 @@ MAIN(boTest) {
testPlan(4+7+11+22);
testdbPrepare();
testdbPrepare();
testdbReadDatabase("recTestIoc.dbd", NULL, NULL);
recTestIoc_registerRecordDeviceDriver(pdbbase);
testdbReadDatabase("boTest.db", NULL, NULL);
eltc(0);
testIocInitOk();
eltc(1);
+1 -1
View File
@@ -653,7 +653,7 @@ void
testAIAveragePartial(void) {
double buf = 0.;
double data[5] = {1., 2., 3., 4., 5.};
/*
/*
* Note that the fifth dbPut essentially resets the circular buffer, so the
* average is once again the average of the _first_ entry alone.
*/
@@ -6,7 +6,7 @@
\*************************************************************************/
/* Compile and link test for epicsExport.h
*
*
* Test if macros eppicsExportAddr, epicsExportRegistrar and epicsRegisterFunction
* expand to valid C and C++ code, in the latter case regardless if
* wrapped with extern "C" {} or not.
@@ -6,7 +6,7 @@
\*************************************************************************/
/* Compile and link test for epicsExport.h
*
*
*/
#include <epicsUnitTest.h>
+4 -4
View File
@@ -146,7 +146,7 @@ static void test_oopt_when_transition_nonzero(void){
/* write a transition to non-zero */
testdbPutFieldOk("longout_rec.VAL", DBF_LONG, 18);
/* Test if the counter_a was processed */
testdbGetFieldEqual("counter_a", DBF_DOUBLE, 1.0);
@@ -156,7 +156,7 @@ static void test_oopt_when_transition_nonzero(void){
static void test_changing_out_field(void){
/* change OOPT to On Change */
testdbPutFieldOk("longout_rec.OOPT", DBF_ENUM, longoutOOPT_On_Change);
/* write an initial value */
testdbPutFieldOk("longout_rec.VAL", DBF_LONG, 16);
@@ -225,7 +225,7 @@ static void test_changing_out_field(void){
/* reset rec processing counters */
testdbPutFieldOk("counter_a.VAL", DBF_DOUBLE, 0.0);
/* test if record with OOPT == On Change will
/* test if record with OOPT == On Change will
write to output at its first process */
testdbPutFieldOk("longout_rec2.VAL", DBF_LONG, 16);
@@ -250,7 +250,7 @@ MAIN(longoutTest) {
recTestIoc_registerRecordDeviceDriver(pdbbase);
testdbReadDatabase("longoutTest.db", NULL, NULL);
eltc(0);
testIocInitOk();
eltc(1);
+7 -7
View File
@@ -196,20 +196,20 @@ static void test_F_format(void){
/* set value on inp0 */
testdbPutFieldOk("test_printf_inp0_rec.VAL", DBF_DOUBLE, 6729982.999);
/* verify that string is formatted as expected */
// visual studio less than 2015 does not support %F
// mingw/gcc also fails, suspect this may be gcc version
// related and checking __GNUC__ could resolve but
// related and checking __GNUC__ could resolve but
// initial attempts didn't work so excluding mingw entirely for now
#ifdef _WIN32
#if (defined(_MSC_VER) && _MSC_VER < 1900) || defined(_MINGW)
testTodoBegin("Fails on windows with old visual studio versions and mingw");
#endif
#endif
testdbGetFieldEqual("test_printf_rec.VAL", DBF_STRING, result_string);
#ifdef _WIN32
#if (defined(_MSC_VER) && _MSC_VER < 1900) || defined(_MINGW)
testTodoEnd();
@@ -422,7 +422,7 @@ static void test_l_flag(void){
/* set value on inp0 */
testdbPutFieldOk("test_printf_inp0_rec.VAL", DBF_LONG, 0x70a1c0c1);
/* verify that string is formatted as expected */
testdbGetFieldEqual("test_printf_rec.VAL", DBF_STRING, result_string);
// number of tests = 3
@@ -532,12 +532,12 @@ MAIN(printfTest) {
testPlan(3+3+3+3+3+3+3+3+4+3+3+3+3+3+3+3+3+3+3+3+3+3+3+3+6+6+12);
testdbPrepare();
testdbPrepare();
testdbReadDatabase("recTestIoc.dbd", NULL, NULL);
recTestIoc_registerRecordDeviceDriver(pdbbase);
testdbReadDatabase("printfTest.db", NULL, NULL);
eltc(0);
testIocInitOk();
eltc(1);
+1 -1
View File
@@ -49,7 +49,7 @@ MAIN(subproctest)
* the testdbPutField call above goes through, so we get a partial
* result of the PROC field being left as 1. */
testdbGetFieldEqual("InvalidINPARec.PROC", DBF_LONG, 1);
testIocShutdownOk();
testdbCleanup();