Avoid using data() of std::vector in woff2_dec

This commit is contained in:
Kenichi Ishibashi
2014-06-04 08:29:53 +09:00
parent 142d8881c1
commit c75ed764ef
+2 -2
View File
@@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.
//
// Library for converting TTF format font files to their WOFF2 versions.
// Library for converting WOFF2 format font files to their TTF versions.
#include "./woff2_dec.h"
@@ -883,7 +883,7 @@ bool ConvertWOFF2ToTTF(uint8_t* result, size_t result_length,
}
if (continue_valid) {
transform_buf += transform_length;
if (transform_buf > uncompressed_buf.data() + uncompressed_buf.size()) {
if (transform_buf > &uncompressed_buf[0] + uncompressed_buf.size()) {
return FONT_COMPRESSION_FAILURE();
}
}