diff --git a/distros/ubuntu1604/zoneminder.install b/distros/ubuntu1604/zoneminder.install index b0b1ad5b6..8a26777c0 100644 --- a/distros/ubuntu1604/zoneminder.install +++ b/distros/ubuntu1604/zoneminder.install @@ -3,7 +3,6 @@ usr/bin usr/lib/zoneminder usr/share/polkit-1 usr/share/zoneminder/db -usr/share/zoneminder/icons usr/share/zoneminder/www # libzoneminder-perl files: diff --git a/distros/ubuntu1604/zoneminder.menu b/distros/ubuntu1604/zoneminder.menu deleted file mode 100644 index fa3f3ff36..000000000 --- a/distros/ubuntu1604/zoneminder.menu +++ /dev/null @@ -1,2 +0,0 @@ -?package(zoneminder):needs="x11" section="Applications/Video" title="ZoneMinder" command="/usr/bin/x-www-browser http://localhost/zm" icon="/usr/share/zoneminder/icons/16x16/icon.xpm" - diff --git a/src/zm_logger.cpp b/src/zm_logger.cpp index 78d9ab934..f122fa1d8 100644 --- a/src/zm_logger.cpp +++ b/src/zm_logger.cpp @@ -194,7 +194,12 @@ void Logger::initialise( const std::string &id, const Options &options ) { level( tempLevel ); - mFlush = (envPtr = getenv( "LOG_FLUSH")) ? atoi( envPtr ) : false; + mFlush = false; + if (envPtr = getenv( "LOG_FLUSH")) { + mFlush = atoi( envPtr ); + } else if ( config.log_debug ) { + mFlush = true; + } //mRuntime = (envPtr = getenv( "LOG_RUNTIME")) ? atoi( envPtr ) : false; { diff --git a/src/zm_zone.cpp b/src/zm_zone.cpp index 433f013a0..6fe629a8c 100644 --- a/src/zm_zone.cpp +++ b/src/zm_zone.cpp @@ -71,6 +71,7 @@ void Zone::Setup( Debug( 1, "Initialised zone %d/%s - %d - %dx%d - Rgb:%06x, CM:%d, MnAT:%d, MxAT:%d, MnAP:%d, MxAP:%d, FB:%dx%d, MnFP:%d, MxFP:%d, MnBS:%d, MxBS:%d, MnB:%d, MxB:%d, OF: %d, AF: %d", id, label, type, polygon.Width(), polygon.Height(), alarm_rgb, check_method, min_pixel_threshold, max_pixel_threshold, min_alarm_pixels, max_alarm_pixels, filter_box.X(), filter_box.Y(), min_filter_pixels, max_filter_pixels, min_blob_pixels, max_blob_pixels, min_blobs, max_blobs, overload_frames, extend_alarm_frames ); alarmed = false; + was_alarmed = false; pixel_diff = 0; alarm_pixels = 0; alarm_filter_pixels = 0; diff --git a/src/zm_zone.h b/src/zm_zone.h index d2576c5d3..bfd39e9aa 100644 --- a/src/zm_zone.h +++ b/src/zm_zone.h @@ -131,14 +131,16 @@ public: inline const Image *AlarmImage() const { return( image ); } inline const Polygon &GetPolygon() const { return( polygon ); } inline bool Alarmed() const { return( alarmed ); } - inline void SetAlarm() { alarmed = true; } - inline void ClearAlarm() { alarmed = false; } + inline bool WasAlarmed() const { return( was_alarmed ); } + inline void SetAlarm() { was_alarmed = alarmed; alarmed = true; } + inline void ClearAlarm() { was_alarmed = alarmed; alarmed = false; } inline Coord GetAlarmCentre() const { return( alarm_centre ); } inline unsigned int Score() const { return( score ); } inline void ResetStats() { alarmed = false; + was_alarmed = false; pixel_diff = 0; alarm_pixels = 0; alarm_filter_pixels = 0; @@ -170,7 +172,6 @@ public: inline const Image *getPgImage() const { return( pg_image ); } inline const Range *getRanges() const { return( ranges ); } - }; #endif // ZM_ZONE_H