[prev in list] [next in list] [prev in thread] [next in thread] 

List:       bacula-commits
Subject:    [Bacula-commits] git: Bacula branch, master,
From:       "Eric Bollengier" <ricozz () users ! sourceforge ! net>
Date:       2009-11-11 16:50:53
Message-ID: E1N8GPH-0004lj-2C () fxgxhf1 ! ch3 ! sourceforge ! com
[Download RAW message or body]

This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "Bacula".

The branch, master has been updated
       via  5fcfebaa7806a397f706e5e5d9a7420a557ff3b8 (commit)
       via  9188721c6b19e1303a90ff64e6581e1b4bc87070 (commit)
      from  ede9231e92d9ba2758112e124830a5a69df65010 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
commit 5fcfebaa7806a397f706e5e5d9a7420a557ff3b8
Author: Eric Bollengier <eric@eb.homelinux.org>
Date:   Wed Nov 11 17:50:29 2009 +0100

    update

commit 9188721c6b19e1303a90ff64e6581e1b4bc87070
Author: Eric Bollengier <eric@eb.homelinux.org>
Date:   Wed Nov 11 17:49:31 2009 +0100

    Fix segfault on basejob code

-----------------------------------------------------------------------

Summary of changes:
diff --git a/bacula/src/cats/sql_get.c b/bacula/src/cats/sql_get.c
index 0bcba5b..340ebd0 100644
--- a/bacula/src/cats/sql_get.c
+++ b/bacula/src/cats/sql_get.c
@@ -1224,14 +1224,16 @@ bool db_get_base_file_list(JCR *jcr, B_DB *mdb,
 
 bool db_get_base_jobid(JCR *jcr, B_DB *mdb, JOB_DBR *jr, JobId_t *jobid)
 {
+   POOL_MEM query(PM_FNAME);
+   utime_t StartTime;
+   db_int64_ctx lctx;
    char date[MAX_TIME_LENGTH];
    bool ret=false;
-   int64_t id = *jobid = 0;
-   POOLMEM *query = get_pool_memory(PM_FNAME);
+   *jobid = 0;
 
 // char clientid[50], filesetid[50];
 
-   utime_t StartTime = (jr->StartTime)?jr->StartTime:time(NULL);
+   StartTime = (jr->StartTime)?jr->StartTime:time(NULL);
    bstrutime(date, sizeof(date),  StartTime + 1);
 
    /* we can take also client name, fileset, etc... */
@@ -1251,17 +1253,16 @@ bool db_get_base_jobid(JCR *jcr, B_DB *mdb, JOB_DBR *jr, JobId_t *jobid)
 //      edit_uint64(jr->FileSetId, filesetid));
         date);
 
-   Dmsg1(10, "db_get_base_jobid q=%s\n", query);
-   if (!db_sql_query(mdb, query, db_int64_handler, &id)) {
+   Dmsg1(10, "db_get_base_jobid q=%s\n", query.c_str());
+   if (!db_sql_query(mdb, query.c_str(), db_int64_handler, &lctx)) {
       goto bail_out;
    }
-   *jobid = (JobId_t) id;
+   *jobid = (JobId_t) lctx.value;
 
-   Dmsg1(10, "db_get_base_jobid=%lld\n", id);
+   Dmsg1(10, "db_get_base_jobid=%lld\n", *jobid);
    ret = true;
 
 bail_out:
-   free_pool_memory(query);
    return ret;
 }
 
diff --git a/bacula/technotes b/bacula/technotes
index d798d34..94dd239 100644
--- a/bacula/technotes
+++ b/bacula/technotes
@@ -2,6 +2,9 @@
           
 General:
 
+11Nov09
+ebl  Fix basejob code for Mysql
+ebl  Fix segfault in basejob code
 05Nov09
 ebl  Display a message if catalog max_connections setting is too low
 04Nov09


hooks/post-receive
-- 
Bacula

------------------------------------------------------------------------------
Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day 
trial. Simplify your report design, integration and deployment - and focus on 
what you do best, core application coding. Discover what's new with
Crystal Reports now.  http://p.sf.net/sfu/bobj-july
_______________________________________________
Bacula-commits mailing list
Bacula-commits@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/bacula-commits
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic