mirror of
https://github.com/hashcat/hashcat.git
synced 2024-12-17 04:08:34 +00:00
Fixed gcc warnings about missing field initializers
This commit is contained in:
parent
2c4ad77275
commit
5d4160dc8c
@ -2630,7 +2630,9 @@ char *logfile_generate_subid ()
|
|||||||
#if F_SETLKW
|
#if F_SETLKW
|
||||||
void lock_file (FILE *fp)
|
void lock_file (FILE *fp)
|
||||||
{
|
{
|
||||||
struct flock lock = { 0 };
|
struct flock lock;
|
||||||
|
|
||||||
|
memset (&lock, 0, sizeof (struct flock));
|
||||||
|
|
||||||
lock.l_type = F_WRLCK;
|
lock.l_type = F_WRLCK;
|
||||||
while (fcntl(fileno(fp), F_SETLKW, &lock))
|
while (fcntl(fileno(fp), F_SETLKW, &lock))
|
||||||
@ -2646,7 +2648,9 @@ void lock_file (FILE *fp)
|
|||||||
|
|
||||||
void unlock_file (FILE *fp)
|
void unlock_file (FILE *fp)
|
||||||
{
|
{
|
||||||
struct flock lock = { 0 };
|
struct flock lock;
|
||||||
|
|
||||||
|
memset (&lock, 0, sizeof (struct flock));
|
||||||
|
|
||||||
lock.l_type = F_UNLCK;
|
lock.l_type = F_UNLCK;
|
||||||
fcntl(fileno(fp), F_SETLK, &lock);
|
fcntl(fileno(fp), F_SETLK, &lock);
|
||||||
|
Loading…
Reference in New Issue
Block a user