X-Git-Url: https://git.sesse.net/?a=blobdiff_plain;ds=sidebyside;f=src%2Fmisc%2Fupdate.c;h=b00eb27bbf79dc78e922472aa6812e329659c9d7;hb=39827e4a5e846bf58a247b22e29cf7b8bbe9c6bc;hp=cefb6e3c62a96b57c97d95e4c79b377d93b11c32;hpb=435a44a809896c13fdc522af6b864494d7fbd0a2;p=vlc diff --git a/src/misc/update.c b/src/misc/update.c index cefb6e3c62..b00eb27bbf 100644 --- a/src/misc/update.c +++ b/src/misc/update.c @@ -307,7 +307,7 @@ static bool GetUpdateFile( update_t *p_update ) goto error; } - uint8_t *p_hash = hash_sha1_from_public_key( p_new_pkey ); + uint8_t *p_hash = hash_from_public_key( p_new_pkey ); if( !p_hash ) { msg_Err( p_update->p_libvlc, "Failed to hash signature" ); @@ -332,17 +332,17 @@ static bool GetUpdateFile( update_t *p_update ) } } - uint8_t *p_hash = hash_sha1_from_text( psz_update_data, &sign ); + uint8_t *p_hash = hash_from_text( psz_update_data, &sign ); if( !p_hash ) { - msg_Warn( p_update->p_libvlc, "Can't compute SHA1 hash for status file" ); + msg_Warn( p_update->p_libvlc, "Can't compute hash for status file" ); goto error; } else if( p_hash[0] != sign.hash_verification[0] || p_hash[1] != sign.hash_verification[1] ) { - msg_Warn( p_update->p_libvlc, "Bad SHA1 hash for status file" ); + msg_Warn( p_update->p_libvlc, "Bad hash for status file" ); free( p_hash ); goto error; } @@ -671,7 +671,7 @@ static void* update_DownloadReal( void *obj ) goto end; } - uint8_t *p_hash = hash_sha1_from_file( psz_destfile, &sign ); + uint8_t *p_hash = hash_from_file( psz_destfile, &sign ); if( !p_hash ) { msg_Err( p_udt, "Unable to hash %s", psz_destfile ); @@ -691,7 +691,7 @@ static void* update_DownloadReal( void *obj ) dialog_FatalWait( p_udt, _("File corrupted"), _("Downloaded file \"%s\" was corrupted. Thus, it was deleted."), psz_destfile ); - msg_Err( p_udt, "Bad SHA1 hash for %s", psz_destfile ); + msg_Err( p_udt, "Bad hash for %s", psz_destfile ); free( p_hash ); goto end; }