From 0530fa2f2d931ebb4baec0e0f636587b6a8996db Mon Sep 17 00:00:00 2001 From: david Date: Sat, 19 Dec 2009 06:08:47 +0000 Subject: [PATCH] Add a lineno member to MatchDetails. --- service_scan.cc | 1 + service_scan.h | 3 +++ 2 files changed, 4 insertions(+) diff --git a/service_scan.cc b/service_scan.cc index d14aac086..604d06a08 100644 --- a/service_scan.cc +++ b/service_scan.cc @@ -484,6 +484,7 @@ const struct MatchDetails *ServiceProbeMatch::testMatch(const u8 *buf, int bufle if (*devicetype) MD_return.devicetype = devicetype; MD_return.serviceName = servicename; + MD_return.lineno = getLineNo(); } return &MD_return; diff --git a/service_scan.h b/service_scan.h index ce6fcb360..da5a77f1d 100644 --- a/service_scan.h +++ b/service_scan.h @@ -124,6 +124,9 @@ struct MatchDetails { // The service that was matched (Or NULL) zero-terminated. const char *serviceName; + // The line number of this match in nmap-service-probes. + int lineno; + // The product/verson/info for the service that was matched (Or NULL) // zero-terminated. const char *product;