src/filed/verify.c
void do_verify(JCR *jcr)
{
   jcr->setJobStatus(JS_Running);

   LockRes();
   CLIENT *client = (CLIENT *)GetNextRes(R_CLIENT, NULL);
   UnlockRes();

   if (client) {
      jcr->buf_size = client->max_network_buffer_size ?
         client->max_network_buffer_size : DEFAULT_NETWORK_BUFFER_SIZE;
   } else {
      jcr->buf_size = DEFAULT_NETWORK_BUFFER_SIZE; /* use default */
   }
   if ((jcr->big_buf = (char *) malloc(jcr->buf_size)) == NULL) {
      Jmsg1(jcr, M_ABORT, 0, _("Cannot malloc %d network read buffer\n"),
         DEFAULT_NETWORK_BUFFER_SIZE);
   }
   set_find_options((FF_PKT *)jcr->ff, jcr->incremental, jcr->mtime);
   Dmsg0(10, "Start find files\n");
   /* Subroutine verify_file() is called for each file */
   find_files(jcr, (FF_PKT *)jcr->ff, verify_file, NULL);
   Dmsg0(10, "End find files\n");

   if (jcr->big_buf) {
      free(jcr->big_buf);
      jcr->big_buf = NULL;
   }
   jcr->setJobStatus(JS_Terminated);
}
/*
 * Find all the requested files and send attributes
 * to the Director.
 *
 */
Find all the requested files and send attributes
to the Director.
Find all the requested files and send attributes to the Director .
void do_verify(JCR *jcr)
{
   jcr->setJobStatus(JS_Running);
   LockRes();
   CLIENT *client = (CLIENT *)GetNextRes(R_CLIENT, NULL);
   UnlockRes();
   if (client) {
      jcr->buf_size = client->max_network_buffer_size ?
         client->max_network_buffer_size : DEFAULT_NETWORK_BUFFER_SIZE;
   } else {
      jcr->buf_size = DEFAULT_NETWORK_BUFFER_SIZE; 
   }
   if ((jcr->big_buf = (char *) malloc(jcr->buf_size)) == NULL) {
      Jmsg1(jcr, M_ABORT, 0, _("Cannot malloc %d network read buffer\n"),
         DEFAULT_NETWORK_BUFFER_SIZE);
   }
   set_find_options((FF_PKT *)jcr->ff, jcr->incremental, jcr->mtime);
   Dmsg0(10, "Start find files\n");
   find_files(jcr, (FF_PKT *)jcr->ff, verify_file, NULL);
   Dmsg0(10, "End find files\n");
   if (jcr->big_buf) {
      free(jcr->big_buf);
      jcr->big_buf = NULL;
   }
   jcr->setJobStatus(JS_Terminated);
}
void do_verify ( JCR * jcr ) { jcr -> setJobStatus ( JS_Running ) ; LockRes ( ) ; CLIENT * client = ( CLIENT * ) GetNextRes ( R_CLIENT , NULL ) ; UnlockRes ( ) ; if ( client ) { jcr -> buf_size = client -> max_network_buffer_size ? client -> max_network_buffer_size : DEFAULT_NETWORK_BUFFER_SIZE ; } else { jcr -> buf_size = DEFAULT_NETWORK_BUFFER_SIZE ; } if ( ( jcr -> big_buf = ( char * ) malloc ( jcr -> buf_size ) ) == NULL ) { Jmsg1 ( jcr , M_ABORT , 0 , _ ( " \n " ) , DEFAULT_NETWORK_BUFFER_SIZE ) ; } set_find_options ( ( FF_PKT * ) jcr -> ff , jcr -> incremental , jcr -> mtime ) ; Dmsg0 ( 10 , " \n " ) ; find_files ( jcr , ( FF_PKT * ) jcr -> ff , verify_file , NULL ) ; Dmsg0 ( 10 , " \n " ) ; if ( jcr -> big_buf ) { free ( jcr -> big_buf ) ; jcr -> big_buf = NULL ; } jcr -> setJobStatus ( JS_Terminated ) ; }
Find all the requested files and send attributes
 to the Director.
Find all the requested files and send attributes to the Director .
/* use default */ /* Subroutine verify_file() is called for each file */