From 503a7210275e0f3e41cc479b81922a19968cf9cf Mon Sep 17 00:00:00 2001 From: "Philipp Lohmann [pl]" Date: Thu, 29 Oct 2009 18:46:44 +0100 Subject: vcl107: #i106443# check fgets (thanks cmc) --- extensions/source/nsplugin/source/so_env.cxx | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'extensions') diff --git a/extensions/source/nsplugin/source/so_env.cxx b/extensions/source/nsplugin/source/so_env.cxx index df23100e3859..92bcab19bd59 100644 --- a/extensions/source/nsplugin/source/so_env.cxx +++ b/extensions/source/nsplugin/source/so_env.cxx @@ -310,7 +310,8 @@ char* NSP_getProductName() char *pEnd = 0; while(!feof(fp)) { - fgets( line, sizeof(line), fp ); + if (fgets( line, sizeof(line), fp ) == NULL) + continue; if (NULL == (pStart = strstr( line, "ProductKey=" ))) continue; pStart += strlen("ProductKey="); -- cgit