Merge pull request #184 from alexcrichton/update
Remove usage of unstable features in openssl-sys
This commit is contained in:
commit
5adbe4b362
|
|
@ -1,5 +1,3 @@
|
||||||
#![feature(path)]
|
|
||||||
|
|
||||||
extern crate "pkg-config" as pkg_config;
|
extern crate "pkg-config" as pkg_config;
|
||||||
extern crate gcc;
|
extern crate gcc;
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,5 @@
|
||||||
#![allow(non_camel_case_types, non_upper_case_globals, non_snake_case)]
|
#![allow(non_camel_case_types, non_upper_case_globals, non_snake_case)]
|
||||||
#![allow(dead_code)]
|
#![allow(dead_code)]
|
||||||
#![feature(path, path_ext)]
|
|
||||||
#![doc(html_root_url="https://sfackler.github.io/rust-openssl/doc/openssl-sys")]
|
#![doc(html_root_url="https://sfackler.github.io/rust-openssl/doc/openssl-sys")]
|
||||||
|
|
||||||
extern crate libc;
|
extern crate libc;
|
||||||
|
|
|
||||||
|
|
@ -1,5 +1,5 @@
|
||||||
use std::env;
|
use std::env;
|
||||||
use std::fs::PathExt;
|
use std::fs;
|
||||||
use std::path::PathBuf;
|
use std::path::PathBuf;
|
||||||
|
|
||||||
pub struct ProbeResult {
|
pub struct ProbeResult {
|
||||||
|
|
@ -25,7 +25,7 @@ pub fn find_certs_dirs() -> Vec<PathBuf> {
|
||||||
"/etc/pki/tls",
|
"/etc/pki/tls",
|
||||||
"/etc/ssl",
|
"/etc/ssl",
|
||||||
].iter().map(|s| PathBuf::new(*s)).filter(|p| {
|
].iter().map(|s| PathBuf::new(*s)).filter(|p| {
|
||||||
p.exists()
|
fs::metadata(p).is_ok()
|
||||||
}).collect()
|
}).collect()
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -67,7 +67,7 @@ pub fn probe() -> ProbeResult {
|
||||||
}
|
}
|
||||||
|
|
||||||
fn try(dst: &mut Option<PathBuf>, val: PathBuf) {
|
fn try(dst: &mut Option<PathBuf>, val: PathBuf) {
|
||||||
if dst.is_none() && val.exists() {
|
if dst.is_none() && fs::metadata(&val).is_ok() {
|
||||||
*dst = Some(val);
|
*dst = Some(val);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue