mirror of
https://github.com/hashcat/hashcat.git
synced 2024-11-15 12:29:35 +00:00
Add goodbye_screen()
This commit is contained in:
parent
6199611eed
commit
6fef4a53fb
@ -147,7 +147,7 @@ static void setup_console ()
|
||||
#endif
|
||||
}
|
||||
|
||||
static void welcome_screen (user_options_t *user_options, const time_t *proc_start)
|
||||
static void welcome_screen (const user_options_t *user_options, const time_t *proc_start)
|
||||
{
|
||||
if (user_options->quiet == true) return;
|
||||
if (user_options->keyspace == true) return;
|
||||
@ -179,6 +179,18 @@ static void welcome_screen (user_options_t *user_options, const time_t *proc_sta
|
||||
}
|
||||
}
|
||||
|
||||
static void goodbye_screen (const user_options_t *user_options, const time_t *proc_start, const time_t *proc_stop)
|
||||
{
|
||||
if (user_options->quiet == true) return;
|
||||
if (user_options->keyspace == true) return;
|
||||
if (user_options->stdout_flag == true) return;
|
||||
if (user_options->show == true) return;
|
||||
if (user_options->left == true) return;
|
||||
|
||||
if (user_options->quiet == false) log_info_nn ("Started: %s", ctime (proc_start));
|
||||
if (user_options->quiet == false) log_info_nn ("Stopped: %s", ctime (proc_stop));
|
||||
}
|
||||
|
||||
static void setup_seeding (const user_options_t *user_options, const time_t proc_start)
|
||||
{
|
||||
if (user_options->rp_gen_seed_chgd == true)
|
||||
@ -3574,10 +3586,7 @@ int main (int argc, char **argv)
|
||||
|
||||
logfile_destroy (logfile_ctx);
|
||||
|
||||
// shutdown
|
||||
|
||||
if (user_options->quiet == false) log_info_nn ("Started: %s", ctime (&proc_start));
|
||||
if (user_options->quiet == false) log_info_nn ("Stopped: %s", ctime (&proc_stop));
|
||||
goodbye_screen (user_options, &proc_start, &proc_stop);
|
||||
|
||||
user_options_destroy (user_options);
|
||||
|
||||
|
13
src/opencl.c
13
src/opencl.c
@ -1307,12 +1307,11 @@ int run_cracker (opencl_ctx_t *opencl_ctx, hc_device_param_t *device_param, hash
|
||||
|
||||
int opencl_ctx_init (opencl_ctx_t *opencl_ctx, const user_options_t *user_options)
|
||||
{
|
||||
if (user_options->keyspace == true)
|
||||
{
|
||||
opencl_ctx->disable = true;
|
||||
opencl_ctx->disable = true;
|
||||
|
||||
return 0;
|
||||
}
|
||||
if (user_options->show == true) return 0;
|
||||
if (user_options->left == true) return 0;
|
||||
if (user_options->keyspace == true) return 0;
|
||||
|
||||
hc_thread_mutex_init (opencl_ctx->mux_dispatcher);
|
||||
hc_thread_mutex_init (opencl_ctx->mux_counter);
|
||||
@ -1476,6 +1475,8 @@ int opencl_ctx_init (opencl_ctx_t *opencl_ctx, const user_options_t *user_option
|
||||
opencl_ctx->platform_devices_cnt = platform_devices_cnt;
|
||||
opencl_ctx->platform_devices = platform_devices;
|
||||
|
||||
opencl_ctx->disable = false;
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
@ -1501,7 +1502,7 @@ void opencl_ctx_destroy (opencl_ctx_t *opencl_ctx)
|
||||
|
||||
int opencl_ctx_devices_init (opencl_ctx_t *opencl_ctx, const user_options_t *user_options)
|
||||
{
|
||||
if (opencl_ctx->disable == 1) return 0;
|
||||
if (opencl_ctx->disable == true) return 0;
|
||||
|
||||
/**
|
||||
* OpenCL devices: simply push all devices from all platforms into the same device array
|
||||
|
@ -249,5 +249,3 @@ int outfile_and_hashfile (outfile_ctx_t *outfile_ctx, const char *hashfile)
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user