Searched hist:105903 (Results 1 - 1 of 1) sorted by relevance
/freebsd-11-stable/lib/libfetch/ | ||
H A D | ftp.c | diff 105903 Thu Oct 24 23:17:32 MDT 2002 njl The FTP connection caching needs a better interface -- connections are closed through _fetch_close() which is the only one who knows the connection REALLY was closed (since ref -> 0). However, FTP keeps its own local cached_connection and checks if it is valid by comparing it to NULL. This is bogus since it may have been freed elsewhere by _fetch_close(). This change checks if we are closing the cached_connection and the ref is 1 (soon to be 0). If so, set cached_connection to NULL so we don't accidentally reuse it. The REAL fix should be to move connection caching to the common.c level (_fetch_* functions) and NULL the cache(s) in _fetch_close(). Then all layers could benefit from caching. |
Completed in 111 milliseconds