fine for sockets
CVS patchset: 1916
CVS date: 1998/01/06 03:20:24
- fixed error messages displayed when opening the database
fails during package installation and removal
- query format of the form '[A%{}]' would drop the static string
+ - fixed fix in 2.4.9 for empty packages which broke -qip on ftp URL's
2.4.10 -> 2.4.11:
- HAVE_SYS_SOCKET_H was mistakingly MACHINE_SYS_SOCKET_H in
oldLead = (struct oldrpmlead *) lead;
fstat(fd, &sb);
- if (sb.st_size < 4) return 1;
+ /* if fd points to a socket, pipe, etc, sb.st_size is *always* zero */
+ if (S_ISREG(sb.st_mode) && sb.st_size < 4) return 1;
if (readLead(fd, lead)) {
return 2;