]> git.sur5r.net Git - bacula/bacula/commitdiff
Enhance Win32 error messages -- fixes bug #1879
authorKern Sibbald <kern@sibbald.com>
Sun, 10 Jun 2012 07:41:05 +0000 (09:41 +0200)
committerKern Sibbald <kern@sibbald.com>
Sat, 20 Apr 2013 12:50:47 +0000 (14:50 +0200)
bacula/src/filed/job.c

index 6636cc11d0b22394a94107cc574f913057bf8a7e..61164699df54b92b8ca49e68bd351842c25cb821 100644 (file)
@@ -1907,7 +1907,9 @@ static int backup_cmd(JCR *jcr)
         if (get_win32_driveletters(jcr->ff, szWinDriveLetters)) {
             Jmsg(jcr, M_INFO, 0, _("Generate VSS snapshots. Driver=\"%s\", Drive(s)=\"%s\"\n"), g_pVSSClient->GetDriverName(), szWinDriveLetters);
             if (!g_pVSSClient->CreateSnapshots(szWinDriveLetters)) {               
-               Jmsg(jcr, M_FATAL, 0, _("CreateSGenerate VSS snapshots failed.\n"));
+               berrno be;
+               Jmsg(jcr, M_FATAL, 0, _("CreateSGenerate VSS snapshots failed. ERR=%s\n"),
+                    be.bstrerror());
             } else {
                /* tell user if snapshot creation of a specific drive failed */
                int i;
@@ -1927,7 +1929,9 @@ static int backup_cmd(JCR *jcr)
             Jmsg(jcr, M_FATAL, 0, _("No drive letters found for generating VSS snapshots.\n"));
         }
       } else {
-         Jmsg(jcr, M_FATAL, 0, _("VSS was not initialized properly.\n"));
+         berrno be;
+         Jmsg(jcr, M_FATAL, 0, _("VSS was not initialized properly. ERR=%s\n"),
+            be.bstrerror());
       } 
       run_scripts(jcr, jcr->RunScripts, "ClientAfterVSS");
    }