Use FBSDID(), WARNS=2 fix.
Mkaefile does not use WARNS=2 beacuse this will be made default.
This commit is contained in:
parent
d46847c026
commit
1c6cde4bb5
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=87678
@ -22,10 +22,12 @@
|
||||
* THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
|
||||
* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
|
||||
* THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
*
|
||||
* $FreeBSD$
|
||||
*/
|
||||
|
||||
#include <sys/cdefs.h>
|
||||
|
||||
__FBSDID("$FreeBSD$");
|
||||
|
||||
#include <sys/stat.h>
|
||||
#include <sys/param.h>
|
||||
|
||||
@ -132,7 +134,7 @@ print_matches(char *path, char *filename)
|
||||
found = 0;
|
||||
while ((d = strsep(&path, ":")) != NULL) {
|
||||
if (snprintf(candidate, sizeof(candidate), "%s/%s", d,
|
||||
filename) >= sizeof(candidate))
|
||||
filename) >= (int)sizeof(candidate))
|
||||
continue;
|
||||
if (is_there(candidate)) {
|
||||
found = 1;
|
||||
|
Loading…
Reference in New Issue
Block a user