13 lines
384 B
Diff
13 lines
384 B
Diff
Return an error if Fileno is called with NULL instead of segfaulting.
|
|
|
|
--- ./rpmio/rpmio.c.orig 2005-01-26 03:39:58.000000000 +0000
|
|
+++ ./rpmio/rpmio.c 2005-12-16 17:51:19.000000000 +0000
|
|
@@ -3094,6 +3164,7 @@ int Fileno(FD_t fd)
|
|
{
|
|
int i, rc = -1;
|
|
|
|
+ if (fd == NULL) return -1;
|
|
if (fd->req != NULL)
|
|
rc = 123456789; /* HACK: https has no steenkin fileno. */
|
|
else
|