Fixed #232 by limiting the allowed number of string to the maximum supported stipple height (32).

This commit is contained in:
Matthias Koefferlein 2019-02-23 09:52:14 +01:00
parent f93dc85c37
commit f40d437a96
1 changed files with 2 additions and 2 deletions

View File

@ -722,8 +722,8 @@ DitherPatternInfo::from_strings (const std::vector<std::string> &strv)
data[l] = 0;
}
for (size_t i = 0; i < strv.size (); ++i) {
uint_from_string (strv [strv.size () - 1 - i].c_str (), data [i], w);
for (size_t i = 0; i < h; ++i) {
uint_from_string (strv [h - 1 - i].c_str (), data [i], w);
}
set_pattern (data, w, h);