diff options
author | Jörg Frings-Fürst <debian@jff-webhosting.net> | 2017-04-14 18:42:48 +0200 |
---|---|---|
committer | Jörg Frings-Fürst <debian@jff-webhosting.net> | 2017-04-14 18:42:48 +0200 |
commit | c0cffd791bfaffaad631076141fcdfc000adcac1 (patch) | |
tree | 18aa64564a5c0abaf8fb908041de106cca11548b /util/oem_supermicro.c | |
parent | e3a9bfc89256e939ab1c1f56f6961b6ee15aa84a (diff) |
New upstream version 3.0.4upstream/3.0.4
Diffstat (limited to 'util/oem_supermicro.c')
-rw-r--r-- | util/oem_supermicro.c | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/util/oem_supermicro.c b/util/oem_supermicro.c index 165bf88..a480b7f 100644 --- a/util/oem_supermicro.c +++ b/util/oem_supermicro.c @@ -68,7 +68,7 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. void set_loglevel(int level); /*prototype */ extern char fsm_debug; /*mem_if.c*/ -static char * progver = "3.03"; +static char * progver = "3.04"; static char * progname = "ismcoem"; static int verbose = 0; static char fdebug = 0; @@ -414,7 +414,8 @@ int decode_threshold_supermicro(uchar rval, uchar *thresh) * non-zero otherwise, to use default interpretations. * pstring = contains the sensor reading interpretation string (if rv==0) */ -int decode_sensor_supermicro(uchar *sdr,uchar *reading,char *pstring, int slen) +int decode_sensor_supermicro(uchar *sdr,uchar *reading,char *pstring, int slen, + int fsimple) { int i, rv = -1; uchar stype, etype, snum; @@ -455,7 +456,9 @@ int decode_sensor_supermicro(uchar *sdr,uchar *reading,char *pstring, int slen) sdr01 = (SDR01REC *)sdr; val = RawToFloat(reading[0],sdr); typestr = get_unit_type(sdr01->sens_units,sdr01->sens_base,sdr01->sens_mod, 0); - snprintf(pstring, slen, "%s %.2f %s",pstr,val,typestr); + if (fsimple) + snprintf(pstring, slen, "%s | %.2f %s",pstr,val,typestr); + else snprintf(pstring, slen, "%s %.2f %s",pstr,val,typestr); return(rv); } switch(stype) { |