Xymon Mailing List Archive search

Patch to correct status unchanged time formatting

list John Horne
Mon, 12 Mar 2012 14:29:53 +0000
Message-Id: <user-934de0d2c170@xymon.invalid>

[Lifted from SF tracker #3498715]

Attached is a trivial patch for the 'Status unchanged in' line displayed
on the web page of individual services. The patch was produced against
version 4.3.7 Xymon.
Currently the 'status unchanged' line shows times like:

   Status unchanged in 1 days,0 hours, 11 minutes

The patch puts a space after the first comma (,). It then only puts an
's' on the time if it is not '1'. So, the above becomes:

   Status unchanged in 1 day, 0 hours, 11 minutes

(The patch is a little messy - using specific variables for the maths
would be better.)


John.

-- 
John Horne                   Tel: +XX (X)XXXX XXXXXX
Plymouth University, UK      Fax: +XX (X)XXXX XXXXXX