8205360: Choose printer defaults

Reviewed-by: prr, mschoene, rhalade
This commit is contained in:
Prasanta Sadhukhan 2018-07-31 11:43:24 +05:30
parent 942c7ec609
commit 43b3a6a6bb

View File

@ -962,9 +962,10 @@ Java_sun_print_Win32PrintService_getDefaultSettings(JNIEnv *env,
if (!present) {
defIndices[0] = papers[0];
}
if (papers != NULL) {
free((char*)papers);
}
}
// If DeviceCapabilities fails, then also free paper allocation
if (papers != NULL) {
free((char*)papers);
}
}
RESTORE_CONTROLWORD