Popovich/clcache — comment on commit e78bd63b31cf32e2569cf95788bf5962846e23e9
File: clcache.py line 275
By frerich:

Ah, this looks like a good bugfix! I guess I didn't notice myself since I never used resource files myself. However, instead of hardcoding u'\ufeff', shouldn't one check for whatever BOM we detected further up? In fact, in the

```python
if rawBytes[:2] == codecs.BOM_UTF16_BE:
encoding = "utf-16-be"
```

checks above, shouldn't we skip the first few bytes directly there, so that the above becomes

```python
if rawBytes[:2] == codecs.BOM_UTF16_BE:
encoding = "utf-16-be"
rawBytes = rawBytes[2:]
```