Fix for upstream changes

This commit is contained in:
Steven Fackler 2014-10-09 20:43:14 -07:00
parent 557a159a8a
commit f62aa26917
2 changed files with 4 additions and 4 deletions

View File

@ -51,7 +51,7 @@
//! }
//! ```
#![doc(html_root_url="http://www.rust-ci.org/sfackler/rust-postgres/doc")]
#![feature(macro_rules, struct_variant, phase, unsafe_destructor)]
#![feature(macro_rules, struct_variant, phase, unsafe_destructor, slicing_syntax)]
#![warn(missing_doc)]
extern crate collections;
@ -487,12 +487,12 @@ impl InnerPostgresConnection {
let hasher = Hasher::new(MD5);
hasher.update(pass.as_bytes());
hasher.update(user.user.as_bytes());
let output = hasher.final()[].to_hex();
let output = hasher.finalize()[].to_hex();
let hasher = Hasher::new(MD5);
hasher.update(output.as_bytes());
hasher.update(salt);
let output = format!("md5{}",
hasher.final()[].to_hex());
hasher.finalize()[].to_hex());
try_pg_conn!(self.write_messages([PasswordMessage {
password: output[]
}]));

View File

@ -1,4 +1,4 @@
#![feature(macro_rules, phase)]
#![feature(macro_rules, phase, slicing_syntax)]
#[phase(plugin, link)]
extern crate postgres;