]> git.sur5r.net Git - bacula/bacula/blobdiff - bacula/src/lib/util.c
Drop removed catalog function prototype.
[bacula/bacula] / bacula / src / lib / util.c
index 430f44b89ab2c2543e8dad83dd0d0d8c69d39634..8a3e56453cb491e77b648bdc581bbe39db81ccfe 100644 (file)
@@ -6,7 +6,7 @@
    The main author of Bacula is Kern Sibbald, with contributions from
    many others, a complete list can be found in the file AUTHORS.
    This program is Free Software; you can redistribute it and/or
    The main author of Bacula is Kern Sibbald, with contributions from
    many others, a complete list can be found in the file AUTHORS.
    This program is Free Software; you can redistribute it and/or
-   modify it under the terms of version two of the GNU General Public
+   modify it under the terms of version three of the GNU Affero General Public
    License as published by the Free Software Foundation and included
    in the file LICENSE.
 
    License as published by the Free Software Foundation and included
    in the file LICENSE.
 
@@ -15,7 +15,7 @@
    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
    General Public License for more details.
 
    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
    General Public License for more details.
 
-   You should have received a copy of the GNU General Public License
+   You should have received a copy of the GNU Affero General Public License
    along with this program; if not, write to the Free Software
    Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
    02110-1301, USA.
    along with this program; if not, write to the Free Software
    Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
    02110-1301, USA.
@@ -397,9 +397,9 @@ const char *job_type_to_str(int type)
 
 /* Convert ActionOnPurge to string (Truncate, Erase, Destroy)
  */
 
 /* Convert ActionOnPurge to string (Truncate, Erase, Destroy)
  */
-char *aop_to_str(int aop, POOL_MEM &ret)
+char *action_on_purge_to_string(int aop, POOL_MEM &ret)
 {
 {
-   if (aop & AOP_TRUNCATE) {
+   if (aop & ON_PURGE_TRUNCATE) {
       pm_strcpy(ret, _("Truncate"));
    }
    if (!aop) {
       pm_strcpy(ret, _("Truncate"));
    }
    if (!aop) {
@@ -718,6 +718,8 @@ void decode_session_key(char *decode, char *session, char *key, int maxlen)
  *  %t = Job type (Backup, ...)
  *  %r = Recipients
  *  %v = Volume name
  *  %t = Job type (Backup, ...)
  *  %r = Recipients
  *  %v = Volume name
+ *  %b = Job Bytes
+ *  %f = Job Files
  *
  *  omsg = edited output message
  *  imsg = input string containing edit codes (%x)
  *
  *  omsg = edited output message
  *  imsg = input string containing edit codes (%x)
@@ -728,7 +730,7 @@ POOLMEM *edit_job_codes(JCR *jcr, char *omsg, char *imsg, const char *to, job_co
 {
    char *p, *q;
    const char *str;
 {
    char *p, *q;
    const char *str;
-   char add[20];
+   char add[50];
    char name[MAX_NAME_LENGTH];
    int i;
 
    char name[MAX_NAME_LENGTH];
    int i;
 
@@ -774,7 +776,7 @@ POOLMEM *edit_job_codes(JCR *jcr, char *omsg, char *imsg, const char *to, job_co
             break;
          case 'l':
             if (jcr) {
             break;
          case 'l':
             if (jcr) {
-               str = job_level_to_str(jcr->get_JobLevel());
+               str = job_level_to_str(jcr->getJobLevel());
             } else {
                str = _("*none*");
             }
             } else {
                str = _("*none*");
             }
@@ -803,9 +805,15 @@ POOLMEM *edit_job_codes(JCR *jcr, char *omsg, char *imsg, const char *to, job_co
                str = _("*none*");
             }
             break;
                str = _("*none*");
             }
             break;
+         case 'f':                    /* Job Files */
+            str = edit_uint64(jcr->JobFiles, add);
+            break;
+         case 'b':                    /* Job Bytes */
+            str = edit_uint64(jcr->JobBytes, add);
+            break;
          case 't':
             if (jcr) {
          case 't':
             if (jcr) {
-               str = job_type_to_str(jcr->get_JobType());
+               str = job_type_to_str(jcr->getJobType());
             } else {
                str = _("*none*");
             }
             } else {
                str = _("*none*");
             }