Use FT_Done_Library instead of FT_Done_Freetype

It is recommended to use FT_Done_Library with FT_New_Library
from freetype document.

Fixes #6191.
This commit is contained in:
Jinwoo Song 2015-05-27 20:21:36 +09:00
parent df2f8d0636
commit 557bb11bde
4 changed files with 5 additions and 5 deletions

View file

@ -4,7 +4,7 @@
use freetype::freetype::FTErrorMethods;
use freetype::freetype::FT_Add_Default_Modules;
use freetype::freetype::FT_Done_FreeType;
use freetype::freetype::FT_Done_Library;
use freetype::freetype::FT_Library;
use freetype::freetype::FT_Memory;
use freetype::freetype::FT_New_Library;
@ -50,7 +50,7 @@ pub struct FontContextHandle {
impl Drop for FreeTypeLibraryHandle {
fn drop(&mut self) {
assert!(!self.ctx.is_null());
unsafe { FT_Done_FreeType(self.ctx) };
unsafe { FT_Done_Library(self.ctx) };
}
}

View file

@ -330,7 +330,7 @@ dependencies = [
[[package]]
name = "freetype"
version = "0.1.0"
source = "git+https://github.com/servo/rust-freetype#f256a9ac84893f0a183b8966de2a3a03d7552b8b"
source = "git+https://github.com/servo/rust-freetype#34db81810ae8be3bef57094c8a378dbe98d2d2c7"
dependencies = [
"libc 0.1.8 (registry+https://github.com/rust-lang/crates.io-index)",
]

2
ports/cef/Cargo.lock generated
View file

@ -338,7 +338,7 @@ dependencies = [
[[package]]
name = "freetype"
version = "0.1.0"
source = "git+https://github.com/servo/rust-freetype#f256a9ac84893f0a183b8966de2a3a03d7552b8b"
source = "git+https://github.com/servo/rust-freetype#34db81810ae8be3bef57094c8a378dbe98d2d2c7"
dependencies = [
"libc 0.1.8 (registry+https://github.com/rust-lang/crates.io-index)",
]

2
ports/gonk/Cargo.lock generated
View file

@ -325,7 +325,7 @@ dependencies = [
[[package]]
name = "freetype"
version = "0.1.0"
source = "git+https://github.com/servo/rust-freetype#f256a9ac84893f0a183b8966de2a3a03d7552b8b"
source = "git+https://github.com/servo/rust-freetype#34db81810ae8be3bef57094c8a378dbe98d2d2c7"
dependencies = [
"libc 0.1.8 (registry+https://github.com/rust-lang/crates.io-index)",
]