Index: mythtv/programs/mythbackend/httpstatus.cpp
===================================================================
--- mythtv.orig/programs/mythbackend/httpstatus.cpp	2009-05-26 17:37:10.000000000 -0400
+++ mythtv/programs/mythbackend/httpstatus.cpp	2009-05-26 19:18:35.000000000 -0400
@@ -364,7 +364,34 @@
 
         // Make sure that the total is always the last element.
         if (fsID == "total")
+        {
+            long long iLiveTV = -1, iDeleted = -1, iExpirable = -1;
+            MSqlQuery query(MSqlQuery::InitCon());
+            query.prepare("SELECT SUM(filesize) FROM recorded "
+                          " WHERE recgroup = :RECGROUP;");
+
+            query.bindValue("RECGROUP", "LiveTV");
+            if (query.exec() && (query.size() > 0) && query.next())
+            {
+                iLiveTV = query.value(0).toLongLong();
+            }
+            query.bindValue("RECGROUP", "Deleted");
+            if (query.exec() && (query.size() > 0) && query.next())
+            {
+                iDeleted = query.value(0).toLongLong();
+            }
+            query.prepare("SELECT SUM(filesize) FROM recorded "
+                          " WHERE autoexpire = 1 "
+                          "   AND recgroup NOT IN ('LiveTV', 'Deleted');");
+            if (query.exec() && (query.size() > 0) && query.next())
+            {
+                iExpirable = query.value(0).toLongLong();
+            }
+            group.setAttribute("livetv", (int)(iLiveTV>>20) );
+            group.setAttribute("deleted", (int)(iDeleted>>20) );
+            group.setAttribute("expirable", (int)(iExpirable>>20) );
             total = group;
+        }
         else
             storage.appendChild(group);
     }
@@ -1156,6 +1183,34 @@
             sRep = c.toString(nFree) + " MB";
             os << sRep << "</li>\r\n";
 
+            if (id == "total")
+            {
+                int nLiveTV    = g.attribute("livetv" , "0" ).toInt();
+                int nDeleted   = g.attribute("deleted", "0" ).toInt();
+                int nExpirable = g.attribute("expirable" , "0" ).toInt();
+                if ((nLiveTV + nDeleted + nExpirable) > 0)
+                {
+                    os << "            <li>Space Available "
+                          "After Auto-expire: ";
+                    sRep = c.toString(nFree + nLiveTV +
+                                      nDeleted + nExpirable) + " MB";
+                    os << sRep << "</li>\r\n";
+                    os << "            <ul>\r\n";
+                    os << "              <li>Space Used by LiveTV: ";
+                    sRep = c.toString(nLiveTV) + " MB";
+                    os << sRep << "</li>\r\n";
+                    os << "              <li>Space Used by "
+                          "Deleted Recordings: ";
+                    sRep = c.toString(nDeleted) + " MB";
+                    os << sRep << "</li>\r\n";
+                    os << "              <li>Space Used by "
+                          "Auto-expirable Recordings: ";
+                    sRep = c.toString(nExpirable) + " MB";
+                    os << sRep << "</li>\r\n";
+                    os << "            </ul>\r\n";
+                }
+            }
+
             os << "          </ul>\r\n"
             << "        </li>\r\n";
 

