]> git.ipfire.org Git - thirdparty/freeradius-server.git/commitdiff
Missing parentheses in sqlite queries
authorArran Cudbard-Bell <a.cudbardb@freeradius.org>
Mon, 22 Dec 2014 03:19:07 +0000 (22:19 -0500)
committerArran Cudbard-Bell <a.cudbardb@freeradius.org>
Mon, 22 Dec 2014 03:19:19 +0000 (22:19 -0500)
raddb/mods-config/sql/main/sqlite/queries.conf

index 1e14bc567aa257557bee3689c706623f8c7ca46c..b67767a23a80e3d1f139c4cfa2c9f8f39b43562e 100644 (file)
@@ -209,7 +209,7 @@ accounting {
                                SET \
                                        acctstoptime = %{%{integer:Event-Timestamp}:-date('now')}, \
                                        acctsessiontime = \
-                                               %{%{integer:Event-Timestamp}:-strftime('%%s', 'now')} \
+                                               (%{%{integer:Event-Timestamp}:-strftime('%%s', 'now')} \
                                                - strftime('%%s', acctstarttime)), \
                                        acctterminatecause = '%{Acct-Terminate-Cause}' \
                                WHERE acctstoptime IS NULL \
@@ -354,7 +354,7 @@ accounting {
                                        '%{NAS-IP-Address}', \
                                        '%{NAS-Port}', \
                                        '%{NAS-Port-Type}', \
-                                       %{%{integer:Event-Timestamp}:-strftime('%%s', 'now')} - %{%{Acct-Session-Time}:-0}), \
+                                       (%{%{integer:Event-Timestamp}:-strftime('%%s', 'now')} - %{%{Acct-Session-Time}:-0}), \
                                        %{%{integer:Event-Timestamp}:-date('now')}, \
                                        %{%{integer:Event-Timestamp}:-date('now')}, \
                                        '%{Acct-Session-Time}', \