mirror of
https://git.freebsd.org/ports.git
synced 2025-05-21 03:23:10 -04:00
configuration file and behave appropriately if its -1. Fixes a SEGV caused by ignoring the return value and just carrying on. . Bump PORTREVISION. PR: 61392
16 lines
455 B
C
16 lines
455 B
C
$FreeBSD$
|
|
|
|
--- ../../deploy/src/javaws/src/share/native/util.c 22 Oct 2003 23:04:17 -0000 1.1.1.1
|
|
+++ ../../deploy/src/javaws/src/share/native/util.c 16 Jan 2004 23:50:11 -0000
|
|
@@ -27,7 +27,10 @@
|
|
|
|
/* Find size of file */
|
|
struct stat statBuf;
|
|
- stat(filename, &statBuf);
|
|
+ if (stat(filename, &statBuf) == -1) {
|
|
+ *buffer = NULL;
|
|
+ return 0;
|
|
+ }
|
|
size = statBuf.st_size;
|
|
|
|
/* Allocate memory for contents */
|