mirror of
https://github.com/librespot-org/librespot.git
synced 2024-12-18 17:11:53 +00:00
Remove deprecation warnings.
This commit is contained in:
parent
a2db3151bc
commit
09e180b0e2
2 changed files with 4 additions and 5 deletions
|
@ -1,6 +1,6 @@
|
||||||
#![crate_name = "librespot"]
|
#![crate_name = "librespot"]
|
||||||
|
|
||||||
#![feature(plugin,zero_one,iter_arith,slice_bytes,mpsc_select)]
|
#![feature(plugin,zero_one,iter_arith,slice_bytes,mpsc_select,clone_from_slice)]
|
||||||
|
|
||||||
#![plugin(protobuf_macros)]
|
#![plugin(protobuf_macros)]
|
||||||
#[macro_use] extern crate lazy_static;
|
#[macro_use] extern crate lazy_static;
|
||||||
|
|
|
@ -1,9 +1,8 @@
|
||||||
use eventual::Async;
|
use eventual::Async;
|
||||||
use protobuf::{self, Message};
|
use protobuf;
|
||||||
use std::any::{Any, TypeId};
|
use std::any::{Any, TypeId};
|
||||||
use std::collections::HashMap;
|
use std::collections::HashMap;
|
||||||
use std::fmt;
|
use std::fmt;
|
||||||
use std::slice::bytes::copy_memory;
|
|
||||||
use std::sync::{Arc, Condvar, Mutex, MutexGuard, Weak};
|
use std::sync::{Arc, Condvar, Mutex, MutexGuard, Weak};
|
||||||
use std::thread;
|
use std::thread;
|
||||||
|
|
||||||
|
@ -35,7 +34,7 @@ impl MetadataTrait for Track {
|
||||||
files: msg.get_file().iter()
|
files: msg.get_file().iter()
|
||||||
.map(|file| {
|
.map(|file| {
|
||||||
let mut dst = [0u8; 20];
|
let mut dst = [0u8; 20];
|
||||||
copy_memory(&file.get_file_id(), &mut dst);
|
dst.clone_from_slice(&file.get_file_id());
|
||||||
FileId(dst)
|
FileId(dst)
|
||||||
})
|
})
|
||||||
.collect(),
|
.collect(),
|
||||||
|
@ -67,7 +66,7 @@ impl MetadataTrait for Album {
|
||||||
covers: msg.get_cover_group().get_image().iter()
|
covers: msg.get_cover_group().get_image().iter()
|
||||||
.map(|image| {
|
.map(|image| {
|
||||||
let mut dst = [0u8; 20];
|
let mut dst = [0u8; 20];
|
||||||
copy_memory(&image.get_file_id(), &mut dst);
|
dst.clone_from_slice(&image.get_file_id());
|
||||||
FileId(dst)
|
FileId(dst)
|
||||||
})
|
})
|
||||||
.collect(),
|
.collect(),
|
||||||
|
|
Loading…
Reference in a new issue