Fixed an old annoying bug where a restored video card wouldn't properly display a blinking cursor; originally, I assumed it was a CRTC register restoration bug, but actually, some supporting variables (eg, cBlinks) were not getting initialized in both the reset() and restore() code paths. This is also a good time to remember that when an uninitialized array from some hardware state gets serialized and deserialized to/from JSON, the array is restored as a series of "null" values, not as "undefined" values, so it's best for any code checking for undefined values to use "== null" rather than "=== undefined".

This commit is contained in:
Jeff Parsons 2017-06-26 08:56:17 -07:00 • committed by Jeff Parsons
commit ed75397b83
10 changed files with 58 additions and 36 deletions

View file

@ -1308,7 +1308,7 @@ class Bus extends Component {
if (aNotify !== undefined) {
if (aNotify[0]) {
dataPort = aNotify[0](port, addrLIP);
if (dataPort === undefined) {
if (dataPort == null) {
dataPort = maskPort;
} else {
dataPort &= maskPort;