Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(189)

Side by Side Diff: third_party/harfbuzz-ng/src/hb-ot-shape-private.hh

Issue 202083003: Fix unsafe shape_plan->face dependency (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « no previous file | third_party/harfbuzz-ng/src/hb-shape-plan.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright © 2010 Google, Inc. 2 * Copyright © 2010 Google, Inc.
3 * 3 *
4 * This is part of HarfBuzz, a text shaping library. 4 * This is part of HarfBuzz, a text shaping library.
5 * 5 *
6 * Permission is hereby granted, without written agreement and without 6 * Permission is hereby granted, without written agreement and without
7 * license or royalty fees, to use, copy, modify, and distribute this 7 * license or royalty fees, to use, copy, modify, and distribute this
8 * software and its documentation for any purpose, provided that the 8 * software and its documentation for any purpose, provided that the
9 * above copyright notice and the following two paragraphs appear in 9 * above copyright notice and the following two paragraphs appear in
10 * all copies of this software. 10 * all copies of this software.
(...skipping 48 matching lines...) Expand 10 before | Expand all | Expand 10 after
59 59
60 struct hb_ot_shape_planner_t 60 struct hb_ot_shape_planner_t
61 { 61 {
62 /* In the order that they are filled in. */ 62 /* In the order that they are filled in. */
63 hb_face_t *face; 63 hb_face_t *face;
64 hb_segment_properties_t props; 64 hb_segment_properties_t props;
65 const struct hb_ot_complex_shaper_t *shaper; 65 const struct hb_ot_complex_shaper_t *shaper;
66 hb_ot_map_builder_t map; 66 hb_ot_map_builder_t map;
67 67
68 hb_ot_shape_planner_t (const hb_shape_plan_t *master_plan) : 68 hb_ot_shape_planner_t (const hb_shape_plan_t *master_plan) :
69 » » » face (master_plan->face), 69 » » » face (master_plan->face_unsafe),
70 props (master_plan->props), 70 props (master_plan->props),
71 shaper (NULL), 71 shaper (NULL),
72 map (face, &props) {} 72 map (face, &props) {}
73 ~hb_ot_shape_planner_t (void) { map.finish (); } 73 ~hb_ot_shape_planner_t (void) { map.finish (); }
74 74
75 inline void compile (hb_ot_shape_plan_t &plan) 75 inline void compile (hb_ot_shape_plan_t &plan)
76 { 76 {
77 plan.props = props; 77 plan.props = props;
78 plan.shaper = shaper; 78 plan.shaper = shaper;
79 map.compile (plan.map); 79 map.compile (plan.map);
80 } 80 }
81 81
82 private: 82 private:
83 NO_COPY (hb_ot_shape_planner_t); 83 NO_COPY (hb_ot_shape_planner_t);
84 }; 84 };
85 85
86 86
87 #endif /* HB_OT_SHAPE_PRIVATE_HH */ 87 #endif /* HB_OT_SHAPE_PRIVATE_HH */
OLDNEW
« no previous file with comments | « no previous file | third_party/harfbuzz-ng/src/hb-shape-plan.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698