*
*/
/*
- Copyright (C) 2000-2003 Kern Sibbald and John Walker
+ Copyright (C) 2000-2004 Kern Sibbald and John Walker
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License as
* except echo the heartbeat to the Director).
*
*/
-int blast_data_to_storage_daemon(JCR *jcr, char *addr)
+bool blast_data_to_storage_daemon(JCR *jcr, char *addr)
{
BSOCK *sd;
- int stat = 1;
+ bool ok = true;
sd = jcr->store_bsock;
if (!bnet_set_buffer_size(sd, buf_size, BNET_SETBUF_WRITE)) {
set_jcr_job_status(jcr, JS_ErrorTerminated);
Jmsg(jcr, M_FATAL, 0, _("Cannot set buffer size FD->SD.\n"));
- return 0;
+ return false;
}
jcr->buf_size = sd->msglen;
/* Subroutine save_file() is called for each file */
if (!find_files(jcr, (FF_PKT *)jcr->ff, save_file, (void *)jcr)) {
- stat = 0; /* error */
+ ok = false; /* error */
set_jcr_job_status(jcr, JS_ErrorTerminated);
- Jmsg(jcr, M_FATAL, 0, _("Find files error.\n"));
+// Jmsg(jcr, M_FATAL, 0, _("Find files error.\n"));
}
stop_heartbeat_monitor(jcr);
free_pool_memory(jcr->compress_buf);
jcr->compress_buf = NULL;
}
- Dmsg1(300, "end blast_data stat=%d\n", stat);
- return stat;
+ Dmsg1(300, "end blast_data stat=%d\n", ok);
+ return ok;
}
/*