Commit 47f17554 authored by Carsten Leonhardt's avatar Carsten Leonhardt

Merge tag 'upstream/9.4.2'

Upstream version 9.4.2
parents 342ed90b bebf413b
Pipeline #35199 failed with stages
in 3 minutes and 10 seconds
Changelog on version 9.4.0
Changelog on version 9.4.2
16Dec18 Release
Release 9.4.2
04Feb19
- Update Windows .def files
- Change create_postgresql_database.in script to be more flexible
- Implement eliminate verify records in dbcheck bug #2434
- Enhance verify-voltocat-test to detect comparing deleted files
- Fix bug #2452 VerifyToCatalog reports deleted files as being new
- Use correct quoting for a character -- fixes previous patch
03Feb19
- Recompile configure.in
- Apply Carsten's multiarch patch fixes bug #2437
- Apply Carsten's patch for adding CPPFLAGS to tools/gigaslam.c compile
- Allow . to terminate sql queries prompts
02Feb19
- baculum: Update Baculum API OpenAPI documentation
29Jan19
- Fix rwlock_test unittest bug #2449 Only call thr_setconcurrency if it's
available. Fix order of linking and installation.
- FixFix spelling errors found by lintian by Carston in bug #2436
- Apply chmods from Leo in bug #2445
28Jan19
- Add license files LICENSE and LICENSE-FOSS to the regression directory
27Jan19
- Display daemon pid in .apiV2 status output
- Attempt to ensure that ctest job output gets uploaded
- Apply varargs patch from Martin for bug 2443
- Apply recv() hide patch from Martin
- Fix lz4.c register compilation from bug #2443
25Jan19
- dbcheck: Improve error message when trying to prune Path records with BVFS is
used.
24Jan19
- Update cdash for version 9.4
19Jan19
- Fix bug #2448 bregex and bwild do not accept -l command line option
- Partial update copyright year
- Fix struct transfer_manager to be class transfer_manager
- Print Device xxx requested by DIR disabled only if verbose is enabled in
SD
- Add migrate-job-no-resource-test to all-disk-tests
- Remove unused berrno call + return
- Remove mention of Beta release from ReleaseNotes
15Jan19
- Fix #3225 about Migration issue when the Job resource is no longer defined
12Jan19
- baculum: Fix restore paths with apostrophe
31Dec18
- baculum: Fix data level
- Change endblock edit to unsigned -- suggested by Martin Simmons
27Dec18
- Update DEPKGS_VERSION
22Dec18
- baculum: Adapt Apache configs to version 2.4
Bugs fixed/closed since last release:
2434 2436 2437 2443 2445 2448 2449 2452 3225
======================================================
Release 9.4.1
21Dec18
- Remove register attribute on variables as it is not supported by newer C++
compilers
20Dec18
- Fix regression from 9.2 when backporting Enterprise code
- Add missing default flag so that configure looks for libs3
Bugs fixed/closed since last release:
==========================================================
16Dec18 Release 9.4.0
14Dec18
- Add copyright and correct name on stop-restart-test
......
......@@ -112,7 +112,7 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
Note: the exact form of the copyright (dates, name, and text formatting)
might vary, but the intent is the same, namely that the full BSD 2-Clause
coypright applies. The file LICENSE-FOSS has a few more details.
copyright applies. The file LICENSE-FOSS has a few more details.
######################################################################
......
Release Notes for Bacula 9.4.0
Release Notes for Bacula 9.4.2
This is a major release (currently a Beta release) comprised of more than
Release 9.4.2
This is a bug fix release for version 9.4.1. It includes a number of bug
fixes and patches. Thanks to the community for your participation.
9 bug reports were closed. This version should fix virtually all
the problems found on FreeBSD.
If you are trying to build the S3 drivers, please remember to use the
community supplied (from Bacula Enterprise) version of libs3.so found at:
https://www.bacula.org/downloads/libs3-20181010.tar.gz
04Feb19
- Update Windows .def files
- Change create_postgresql_database.in script to be more flexible
- Implement eliminate verify records in dbcheck bug #2434
- Enhance verify-voltocat-test to detect comparing deleted files
- Fix bug #2452 VerifyToCatalog reports deleted files as being new
- Use correct quoting for a character -- fixes previous patch
- Recompile configure.in
- Apply Carsten's multiarch patch fixes bug #2437
- Apply Carsten's patch for adding CPPFLAGS to tools/gigaslam.c compile
- Allow . to terminate sql queries prompts
- baculum: Update Baculum API OpenAPI documentation
- Fix rwlock_test unittest bug #2449 Only call thr_setconcurrency if it's
available. Fix order of linking and installation.
- FixFix spelling errors found by lintian by Carston in bug #2436
- Apply chmods from Leo in bug #2445
- Add license files LICENSE and LICENSE-FOSS to the regression directory
- Display daemon pid in .apiV2 status output
- Attempt to ensure that ctest job output gets uploaded
- Apply varargs patch from Martin for bug 2443
- Apply recv() hide patch from Martin
- Fix lz4.c register compilation from bug #2443
- dbcheck: Improve error message when trying to prune Path records with BVFS is
used.
- Update cdash for version 9.4
- Fix bug #2448 bregex and bwild do not accept -l command line option
- Partial update copyright year
- Fix struct transfer_manager to be class transfer_manager
- Print Device xxx requested by DIR disabled only if verbose is enabled in
SD
- Add migrate-job-no-resource-test to all-disk-tests
- Remove unused berrno call + return
- Remove mention of Beta release from ReleaseNotes
- Fix #3225 about Migration issue when the Job resource is no longer defined
- baculum: Fix restore paths with apostrophe
- baculum: Fix data level
- Change endblock edit to unsigned -- suggested by Martin Simmons
- Update DEPKGS_VERSION
- baculum: Adapt Apache configs to version 2.4
Bugs fixed/closed since last release:
2434 2436 2437 2443 2445 2448 2449 2452 3225
====================================================================
Release 9.4.1
This is a minor bug fix release for 9.4.0. It should fix a few of
the warning messages, but not all, on FreeBSD and Solaris. More importantly
The ./configure process now properly detects that libs3 is installed
on your system. If you do not want to use the Amazon S3 driver, this
update is not required.
In addition to this release, I have posted the current source code with
patches for libs3 to bacula.org. This package is needed if you wish to
build the S3 driver. You may download it from the following location:
https://www.bacula.org/downloads/libs3-20181010.tar.gz
21Dec18
- Remove register attribute on variables as it is not supported by newer C++
compilers
- Fix regression from 9.2 when backporting Enterprise code in bsock code
- Add missing default flag so that configure looks for libs3
=====================================================================
Release 9.4.0
This is a major release comprised of more than
13,000 lines of differences since version 9.2.2. It has updates to Baculum
and small number of bug fixes and back ports from Bacula Systems Enterprise
since version 9.2.2, but primarily it has two new features ...
......
......@@ -763,7 +763,9 @@ AC_HELP_STRING([--with-sqlite3@<:@=DIR@:>@], [Include SQLite3 support. DIR is th
SQLITE_BINDIR=/usr/local/bin
elif test -f /usr/include/sqlite3.h; then
SQLITE_INCDIR=/usr/include
if test -d /usr/lib64; then
if test -n $multiarch -a -d /usr/lib/$multiarch; then
SQLITE_LIBDIR=/usr/lib/$multiarch
elif test -d /usr/lib64; then
SQLITE_LIBDIR=/usr/lib64
else
SQLITE_LIBDIR=/usr/lib
......
......@@ -121,6 +121,13 @@ if test ! -e $CXX; then
AC_MSG_ERROR(Unable to find C++ compiler)
fi
dnl -------------------------------------------------------
dnl Check for multiarch.
dnl ------------------------------------------------------
AC_MSG_CHECKING(for multiarch system)
multiarch=`$CC $CFLAGS -print-multiarch 2>/dev/null`
AC_MSG_RESULT($multiarch)
dnl -------------------------------------------------------
dnl Check for programs.
dnl ------------------------------------------------------
......
#! /bin/sh
# Guess values for system-dependent variables and create Makefiles.
# Generated by GNU Autoconf 2.69 for bacula 9.4.0.
# Generated by GNU Autoconf 2.69 for bacula 9.4.2.
#
#
# Copyright (C) 1992-1996, 1998-2012 Free Software Foundation, Inc.
......@@ -587,8 +587,8 @@ MAKEFLAGS=
# Identity of this package.
PACKAGE_NAME='bacula'
PACKAGE_TARNAME='bacula'
PACKAGE_VERSION='9.4.0'
PACKAGE_STRING='bacula 9.4.0'
PACKAGE_VERSION='9.4.2'
PACKAGE_STRING='bacula 9.4.2'
PACKAGE_BUGREPORT=''
PACKAGE_URL=''
......@@ -1588,7 +1588,7 @@ if test "$ac_init_help" = "long"; then
# Omit some internal or obsolete options to make the list less imposing.
# This message is too long to be a string in the A/UX 3.1 sh.
cat <<_ACEOF
\`configure' configures bacula 9.4.0 to adapt to many kinds of systems.
\`configure' configures bacula 9.4.2 to adapt to many kinds of systems.
Usage: $0 [OPTION]... [VAR=VALUE]...
......@@ -1658,7 +1658,7 @@ fi
if test -n "$ac_init_help"; then
case $ac_init_help in
short | recursive ) echo "Configuration of bacula 9.4.0:";;
short | recursive ) echo "Configuration of bacula 9.4.2:";;
esac
cat <<\_ACEOF
......@@ -1857,7 +1857,7 @@ fi
test -n "$ac_init_help" && exit $ac_status
if $ac_init_version; then
cat <<\_ACEOF
bacula configure 9.4.0
bacula configure 9.4.2
generated by GNU Autoconf 2.69
Copyright (C) 2012 Free Software Foundation, Inc.
......@@ -2792,7 +2792,7 @@ cat >config.log <<_ACEOF
This file contains any messages produced by compilers while
running configure, to aid debugging if configure makes a mistake.
It was created by bacula $as_me 9.4.0, which was
It was created by bacula $as_me 9.4.2, which was
generated by GNU Autoconf 2.69. Invocation command line was
$ $0 $@
......@@ -4847,6 +4847,12 @@ if test ! -e $CXX; then
as_fn_error $? "Unable to find C++ compiler" "$LINENO" 5
fi
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for multiarch system" >&5
$as_echo_n "checking for multiarch system... " >&6; }
multiarch=`$CC $CFLAGS -print-multiarch 2>/dev/null`
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $multiarch" >&5
$as_echo "$multiarch" >&6; }
# Find a good install program. We prefer a C program (faster),
# so one script is as good as another. But avoid the broken or
# incompatible versions:
......@@ -24612,7 +24618,9 @@ if test "${with_sqlite3+set}" = set; then :
SQLITE_BINDIR=/usr/local/bin
elif test -f /usr/include/sqlite3.h; then
SQLITE_INCDIR=/usr/include
if test -d /usr/lib64; then
if test -n $multiarch -a -d /usr/lib/$multiarch; then
SQLITE_LIBDIR=/usr/lib/$multiarch
elif test -d /usr/lib64; then
SQLITE_LIBDIR=/usr/lib64
else
SQLITE_LIBDIR=/usr/lib
......@@ -31791,7 +31799,7 @@ cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
# report actual input values of CONFIG_FILES etc. instead of their
# values after options handling.
ac_log="
This file was extended by bacula $as_me 9.4.0, which was
This file was extended by bacula $as_me 9.4.2, which was
generated by GNU Autoconf 2.69. Invocation command line was
CONFIG_FILES = $CONFIG_FILES
......@@ -31857,7 +31865,7 @@ _ACEOF
cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
ac_cs_version="\\
bacula config.status 9.4.0
bacula config.status 9.4.2
configured by $0, generated by GNU Autoconf 2.69,
with options \\"\$ac_cs_config\\"
......
File mode changed from 100644 to 100755
File mode changed from 100644 to 100755
File mode changed from 100644 to 100755
File mode changed from 100644 to 100755
File mode changed from 100644 to 100755
File mode changed from 100755 to 100644
File mode changed from 100644 to 100755
File mode changed from 100644 to 100755
/*
Bacula(R) - The Network Backup Solution
Copyright (C) 2000-2017 Kern Sibbald
Copyright (C) 2000-2019 Kern Sibbald
The original author of Bacula is Kern Sibbald, with contributions
from many others, a complete list can be found in the file AUTHORS.
......
/*
Bacula(R) - The Network Backup Solution
Copyright (C) 2000-2017 Kern Sibbald
Copyright (C) 2000-2019 Kern Sibbald
The original author of Bacula is Kern Sibbald, with contributions
from many others, a complete list can be found in the file AUTHORS.
......
/*
Bacula(R) - The Network Backup Solution
Copyright (C) 2000-2017 Kern Sibbald
Copyright (C) 2000-2019 Kern Sibbald
The original author of Bacula is Kern Sibbald, with contributions
from many others, a complete list can be found in the file AUTHORS.
......
#
# Copyright (C) 2000-2018 Kern Sibbald
# Copyright (C) 2000-2019 Kern Sibbald
# License: BSD 2-Clause; see file LICENSE-FOSS
#
/*
Bacula(R) - The Network Backup Solution
Copyright (C) 2000-2018 Kern Sibbald
Copyright (C) 2000-2019 Kern Sibbald
The original author of Bacula is Kern Sibbald, with contributions
from many others, a complete list can be found in the file AUTHORS.
......
#!/bin/sh
#
# Copyright (C) 2000-2017 Kern Sibbald
# Copyright (C) 2000-2019 Kern Sibbald
# License: BSD 2-Clause; see file LICENSE-FOSS
#
# shell script to create Bacula database(s)
......@@ -18,14 +18,13 @@ PSQLVERSION=`psql -d template1 -c 'select version()' $* | awk '/PostgreSQL/ {pri
#
# Note, LC_COLLATE and LC_TYPE are needed on 8.4 and beyond, but are
# not implemented in 8.3 or below.
# This must be updated for future versions of PostgreSQL
#
case ${PSQLVERSION} in
8.[456789] | 9.* | 10.*)
ENCODING="ENCODING 'SQL_ASCII' LC_COLLATE 'C' LC_CTYPE 'C'"
6.* | 7.* | 8.[0123])
ENCODING="ENCODING 'SQL_ASCII'"
;;
*)
ENCODING="ENCODING 'SQL_ASCII'"
ENCODING="ENCODING 'SQL_ASCII' LC_COLLATE 'C' LC_CTYPE 'C'"
;;
esac
......@@ -53,7 +52,7 @@ else
echo "!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!"
exit 1
fi
if psql -l | grep " ${db_name}.*SQL_ASCII" >/dev/null; then
if psql -l $* | grep " ${db_name}.*SQL_ASCII" >/dev/null; then
echo "Database encoding OK"
else
echo " "
......
......@@ -375,7 +375,7 @@ int BDB::bdb_update_media_record(JCR *jcr, MEDIA_DBR *mr)
"LabelType=%d,StorageId=%s,PoolId=%s,VolRetention=%s,VolUseDuration=%s,"
"MaxVolJobs=%d,MaxVolFiles=%d,Enabled=%d,LocationId=%s,"
"ScratchPoolId=%s,RecyclePoolId=%s,RecycleCount=%d,Recycle=%d,"
"ActionOnPurge=%d,CacheRetention=%s,EndBlock=%d"
"ActionOnPurge=%d,CacheRetention=%s,EndBlock=%u"
" WHERE VolumeName='%s'",
mr->VolJobs, mr->VolFiles, mr->VolBlocks,
edit_uint64(mr->VolBytes, ed1),
......
/*
Bacula(R) - The Network Backup Solution
Copyright (C) 2000-2017 Kern Sibbald
Copyright (C) 2000-2019 Kern Sibbald
The original author of Bacula is Kern Sibbald, with contributions
from many others, a complete list can be found in the file AUTHORS.
......
......@@ -1459,7 +1459,6 @@ static void cleanup_old_files()
char prbuf[500];
const int nmatch = 30;
regmatch_t pmatch[nmatch];
berrno be;
/* Exclude spaces and look for .mail, .tmp or .restore.xx.bsr files */
const char *pat1 = "^[^ ]+\\.(restore\\.[^ ]+\\.bsr|mail|tmp)$";
......@@ -1489,7 +1488,6 @@ static void cleanup_old_files()
Pmsg2(000, "Failed to open working dir %s for cleanup: ERR=%s\n",
director->working_directory, be.bstrerror());
goto get_out1;
return;
}
while (1) {
......
......@@ -673,7 +673,8 @@ void mac_cleanup(JCR *jcr, int TermCode, int writeTermCode)
goterrors = jcr->SDErrors > 0 || jcr->JobErrors > 0 ||
jcr->SDJobStatus == JS_Canceled ||
jcr->SDJobStatus == JS_ErrorTerminated ||
jcr->SDJobStatus == JS_FatalError;
jcr->SDJobStatus == JS_FatalError ||
jcr->JobStatus == JS_FatalError;
if (goterrors && jcr->getJobType() == JT_MIGRATE && jcr->JobStatus == JS_Terminated) {
Jmsg(jcr, M_WARNING, 0, _("Found errors during the migration process. "
......@@ -786,39 +787,44 @@ void mac_cleanup(JCR *jcr, int TermCode, int writeTermCode)
JS_ErrorTerminated, new_jobid);
db_sql_query(wjcr->db, query.c_str(), NULL, NULL);
}
}
switch (jcr->JobStatus) {
case JS_Terminated:
if (jcr->JobErrors || jcr->SDErrors) {
Mmsg(term_msg, _("%%s OK -- %s"), jcr->StatusErrMsg[0] ? jcr->StatusErrMsg : _("with warnings"));
} else {
Mmsg(term_msg, _("%%s OK"));
}
break;
case JS_FatalError:
case JS_ErrorTerminated:
Mmsg(term_msg, _("*** %%s Error ***"));
msg_type = M_ERROR; /* Generate error message */
terminate_sd_msg_chan_thread(jcr);
terminate_sd_msg_chan_thread(wjcr);
break;
case JS_Canceled:
Mmsg(term_msg, _("%%s Canceled"));
terminate_sd_msg_chan_thread(jcr);
terminate_sd_msg_chan_thread(wjcr);
break;
default:
Mmsg(term_msg, _("Inappropriate %s term code"));
break;
switch (jcr->JobStatus) {
case JS_Terminated:
if (jcr->JobErrors || jcr->SDErrors) {
Mmsg(term_msg, _("%%s OK -- %s"), jcr->StatusErrMsg[0] ? jcr->StatusErrMsg : _("with warnings"));
} else {
Mmsg(term_msg, _("%%s OK"));
}
} else {
if (!goterrors && jcr->getJobType() == JT_MIGRATE && jcr->previous_jr.JobId != 0) {
/* Mark previous job as migrated */
Mmsg(query, "UPDATE Job SET Type='%c' WHERE JobId=%s",
(char)JT_MIGRATED_JOB, edit_uint64(jcr->previous_jr.JobId, ec1));
db_sql_query(jcr->db, query.c_str(), NULL, NULL);
break;
case JS_FatalError:
case JS_ErrorTerminated:
Mmsg(term_msg, _("*** %%s Error ***"));
msg_type = M_ERROR; /* Generate error message */
terminate_sd_msg_chan_thread(jcr);
terminate_sd_msg_chan_thread(wjcr);
break;
case JS_Canceled:
Mmsg(term_msg, _("%%s Canceled"));
terminate_sd_msg_chan_thread(jcr);
terminate_sd_msg_chan_thread(wjcr);
break;
default:
Mmsg(term_msg, _("Inappropriate %s term code"));
break;
}
if (!wjcr) { /* We did nothing */
goterrors = jcr->JobErrors > 0 || jcr->JobStatus == JS_FatalError;
if (!goterrors) {
if (jcr->getJobType() == JT_MIGRATE && jcr->previous_jr.JobId != 0) {
/* Mark previous job as migrated */
Mmsg(query, "UPDATE Job SET Type='%c' WHERE JobId=%s",
(char)JT_MIGRATED_JOB, edit_uint64(jcr->previous_jr.JobId, ec1));
db_sql_query(jcr->db, query.c_str(), NULL, NULL);
}
Mmsg(term_msg, _("%%s -- no files to %%s"));
}
Mmsg(term_msg, _("%%s -- no files to %%s"));
}
Mmsg(term_code, term_msg.c_str(), jcr->get_OperationName(), jcr->get_ActionName(0));
......
......@@ -503,7 +503,7 @@ void wait_for_storage_daemon_termination(JCR *jcr)
void terminate_sd_msg_chan_thread(JCR *jcr)
{
if (jcr->store_bsock) {
if (jcr && jcr->store_bsock) {
jcr->store_bsock->signal(BNET_TERMINATE);
jcr->lock();
if ( !jcr->sd_msg_thread_done
......
......@@ -60,7 +60,7 @@ bool newVolume(JCR *jcr, MEDIA_DBR *mr, STORE *store, POOL_MEM &errmsg)
if (pr.MaxVols > 0 && pr.NumVols >= pr.MaxVols) {
Mmsg(errmsg, "Maximum Volumes exceeded for Pool %s", pr.Name);
Dmsg1(90, "Too much volumes for Pool %s\n", pr.Name);
Dmsg1(90, "Too many volumes for Pool %s\n", pr.Name);
goto bail_out;
}
......
......@@ -276,7 +276,8 @@ int sqlquery_cmd(UAContext *ua, const char *cmd)
while (get_cmd(ua, msg)) {
len = strlen(ua->cmd);
Dmsg2(400, "len=%d cmd=%s:\n", len, ua->cmd);
if (len == 0) {
/* Break on empty or . */
if (len == 0 || (len == 1 && ua->cmd[0] == '.')) {
break;
}
if (*query.c_str() != 0) {
......
......@@ -436,6 +436,7 @@ static void api_list_dir_status_header(UAContext *ua)
OT_STRING, "uname", HOST_OS " " DISTNAME " " DISTVER,
OT_UTIME, "started", daemon_start_time,
OT_UTIME, "reloaded", last_reload_time,
OT_INT64, "pid", (int64_t)getpid(),
OT_INT, "jobs_run", num_jobs_run,
OT_INT, "jobs_running",job_count(),
OT_INT, "nclients", ((rblist *)res_head[R_CLIENT-r_first]->res_list)->size(),
......
......@@ -676,6 +676,10 @@ void get_attributes_and_compare_to_catalog(JCR *jcr, JobId_t JobId)
* Find equivalent record in the database
*/
fdbr.FileId = 0;
/* Don't look for deleted records */
if (jcr->FileIndex <= 0) {
continue;
}
if (!db_get_file_attributes_record(jcr, jcr->db, jcr->fname,
&jcr->previous_jr, &fdbr)) {
Jmsg(jcr, M_INFO, 0, _("New file: %s\n"), jcr->fname);
......
......@@ -89,6 +89,7 @@ static void api_list_status_header(STATUS_PKT *sp)
OT_STRING, "version", VERSION " (" BDATE ")",
OT_STRING, "uname", HOST_OS " " DISTNAME " " DISTVER,
OT_UTIME, "started", daemon_start_time,
OT_INT64, "pid", (int64_t)getpid(),
OT_INT, "jobs_run", num_jobs_run,
OT_INT, "jobs_running",job_count(),
OT_STRING, "winver", buf,
......
/*
Bacula(R) - The Network Backup Solution
Copyright (C) 2000-2017 Kern Sibbald
Copyright (C) 2000-2019 Kern Sibbald
The original author of Bacula is Kern Sibbald, with contributions
from many others, a complete list can be found in the file AUTHORS.
......
/*
Bacula(R) - The Network Backup Solution
Copyright (C) 2000-2017 Kern Sibbald
Copyright (C) 2000-2019 Kern Sibbald
The original author of Bacula is Kern Sibbald, with contributions
from many others, a complete list can be found in the file AUTHORS.
......
/*
Bacula(R) - The Network Backup Solution
Copyright (C) 2000-2017 Kern Sibbald
Copyright (C) 2000-2019 Kern Sibbald
The original author of Bacula is Kern Sibbald, with contributions
from many others, a complete list can be found in the file AUTHORS.
......
......@@ -185,8 +185,8 @@ workq_test: Makefile workq.c
rwlock_test: Makefile rwlock.c
$(RMF) rwlock.o
$(CXX) -DTEST_RWLOCK $(DEFS) $(DEBUG) -c $(CPPFLAGS) -I$(srcdir) -I$(basedir) $(DINCLUDE) $(CFLAGS) rwlock.c
$(LIBTOOL_INSTALL) $(INSTALL_PROGRAM) $@ $(DESTDIR)$(sbindir)/
$(LIBTOOL_LINK) $(CXX) $(LDFLAGS) -L. -o $@ rwlock.o $(DLIB) -lbac -lm $(LIBS) $(OPENSSL_LIBS)
$(LIBTOOL_INSTALL) $(INSTALL_PROGRAM) $@ $(DESTDIR)$(sbindir)/
$(RMF) rwlock.o
$(CXX) $(DEFS) $(DEBUG) -c $(CPPFLAGS) -I$(srcdir) -I$(basedir) $(DINCLUDE) $(CFLAGS) rwlock.c
......
......@@ -590,7 +590,7 @@ bool BSOCKCORE::fsend(const char *fmt, ...)
* Returns number of bytes read (may return zero), the msglen is set accordingly.
* Returns -1 on error so msglen will be zero.
*/
int32_t BSOCKCORE::recv(int len)
int32_t BSOCKCORE::recvn(int len)
{
/* The method has to be redesigned from scratch */
int32_t nbytes;
......
......@@ -137,7 +137,7 @@ public:
bool connect(JCR * jcr, int retry_interval, utime_t max_retry_time,
utime_t heart_beat, const char *name, char *host,
char *service, int port, int verbose);
virtual int32_t recv(int /*len*/);
virtual int32_t recvn(int /*len*/);
virtual bool send();
bool fsend(const char*, ...);
void close(); /* close connection and destroy packet */
......
......@@ -228,7 +228,7 @@ int bthread_kill(pthread_t thread, int sig,
#else /* !USE_LOCKMGR */
# define lmgr_detect_deadloc()
# define lmgr_detect_deadlock()
# define lmgr_add_event_p(c, u, f, l)
# define lmgr_add_event(c, u)
# define lmgr_dump()
......
......@@ -30,6 +30,8 @@
You can contact the author at :
- LZ4 homepage : http://www.lz4.org
- LZ4 source repository : https://github.com/lz4/lz4
Tweaked for proper compliation in Bacula by KES 27 Jan 2019
*/
......@@ -307,7 +309,7 @@ static const int LZ4_minLength = (MFLIMIT+1);
/*-************************************
* Common functions
**************************************/
static unsigned LZ4_NbCommonBytes (register reg_t val)
static unsigned LZ4_NbCommonBytes (reg_t val)
{
if (LZ4_isLittleEndian()) {
if (sizeof(val)==8) {
......
/*
Bacula(R) - The Network Backup Solution
Copyright (C) 2000-2018 Kern Sibbald
Copyright (C) 2000-2019 Kern Sibbald
The original author of Bacula is Kern Sibbald, with contributions
from many others, a complete list can be found in the file AUTHORS.
......@@ -25,7 +25,7 @@
#include "bacula.h"
typedef enum {
enum _OutputType {
OT_INT, /* Integer */
OT_SIZE, /* int64 size */
OT_PINT32, /* Uint32 */
......@@ -47,7 +47,9 @@ typedef enum {
OT_END_OBJ, /* Skip a line to end current object (no extra arg) */
OT_CLEAR, /* truncate current buffer (no extra arg) */
OT_DURATION /* time duration in second */
} OutputType;
};
/* Force OutputType to int to avoid compiler default conversion warnings */
typedef int OutputType;
/* Keep the same order for get_options/parse_options */
typedef enum {
......
......@@ -445,7 +445,10 @@ int main (int argc, char *argv[])
* For Solaris 2.5,2.6,7 and 8 threads are not timesliced.
* Ensure our threads can run concurrently.
*/
#ifdef USE_THR_SETCONCURRENCY
thr_setconcurrency(THREADS); /* Only implemented on Solaris */
#endif
/*
* Initialize the shared data.
......
......@@ -15,7 +15,7 @@
** For disclaimer see below.
*/
/*
* Modified for use with Bacula by Kern Sibbald, June 2003
* Modified for use with Bacula by Kern Sibbald, June 2003, Jan 2019