fix for a bug introduced in the DE-LD021 driver

git-svn-id: https://ssl.bulix.org/svn/lcd4linux/trunk@1140 3ae390bd-cb1e-0410-b409-cd5a39f66f1f
This commit is contained in:
michael
2011-01-05 03:49:07 +00:00
parent f95cad51ea
commit 72e1f7501b
+3 -3
View File
@@ -325,10 +325,10 @@ static int drv_MO_start(const char *section, const int quiet)
Model = -1;
}
if (Models[i].protocol == 3) { // Sure electronics USB LCD board - full line output
if (Model != -1 && Models[Model].protocol == 3) { // Sure electronics USB LCD board - full line output
int i, j;
for (i = 0; i < Models[i].rows; i++) { // Clear buffer
for (j = 0; j < Models[i].cols; j++) {
for (i = 0; i < Models[Model].rows; i++) { // Clear buffer
for (j = 0; j < Models[Model].cols; j++) {
dispBuffer[i][j] = ' ';
}
}