summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--vcl/source/fontsubset/ttcr.cxx16
1 files changed, 10 insertions, 6 deletions
diff --git a/vcl/source/fontsubset/ttcr.cxx b/vcl/source/fontsubset/ttcr.cxx
index 4356636e90a2..169092e2ee50 100644
--- a/vcl/source/fontsubset/ttcr.cxx
+++ b/vcl/source/fontsubset/ttcr.cxx
@@ -292,15 +292,19 @@ int AddTable(TrueTypeCreator *_this, TrueTypeTable *table)
void RemoveTable(TrueTypeCreator *_this, sal_uInt32 tag)
{
- int done = 0;
-
- if (listCount(_this->tables)) {
+ if (listCount(_this->tables))
+ {
listToFirst(_this->tables);
+ int done = 0;
do {
- if (((TrueTypeTable *) listCurrent(_this->tables))->tag == tag) {
+ if (((TrueTypeTable *) listCurrent(_this->tables))->tag == tag)
+ {
listRemove(_this->tables);
- } else {
- if (listNext(_this->tables)) {
+ }
+ else
+ {
+ if (listNext(_this->tables))
+ {
done = 1;
}
}