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 gcc;
|
||||
|
||||
|
|
|
|||
|
|
@ -1,6 +1,5 @@
|
|||
#![allow(non_camel_case_types, non_upper_case_globals, non_snake_case)]
|
||||
#![allow(dead_code)]
|
||||
#![feature(path, path_ext)]
|
||||
#![doc(html_root_url="https://sfackler.github.io/rust-openssl/doc/openssl-sys")]
|
||||
|
||||
extern crate libc;
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
use std::env;
|
||||
use std::fs::PathExt;
|
||||
use std::fs;
|
||||
use std::path::PathBuf;
|
||||
|
||||
pub struct ProbeResult {
|
||||
|
|
@ -25,7 +25,7 @@ pub fn find_certs_dirs() -> Vec<PathBuf> {
|
|||
"/etc/pki/tls",
|
||||
"/etc/ssl",
|
||||
].iter().map(|s| PathBuf::new(*s)).filter(|p| {
|
||||
p.exists()
|
||||
fs::metadata(p).is_ok()
|
||||
}).collect()
|
||||
}
|
||||
|
||||
|
|
@ -67,7 +67,7 @@ pub fn probe() -> ProbeResult {
|
|||
}
|
||||
|
||||
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);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue