opnsense-ports/www/swish++/files/patch-search.c
Franco Fichtner 8cb1a96ede ports: pull in a snapshot of the FreeBSD ports tree
Taken from:	https://github.com/freebsd/freebsd-ports.git
Commit id:	5070672073b68be364139bc6b3a89100bd17d331
2014-11-09 14:03:21 +01:00

18 lines
628 B
C

--- search.c.orig
+++ search.c
@@ -520,11 +520,11 @@
r != sorted.end() && max_results-- > 0 && out; ++r
) {
// cast gets rid of warning
- int rank = static_cast<int>( r->second * normalize );
- if ( !rank )
- rank = 1;
+ int my_rank = static_cast<int>( r->second * normalize );
+ if ( !my_rank )
+ my_rank = 1;
format->result(
- rank,
+ my_rank,
file_info(
reinterpret_cast<unsigned char const*>( files[ r->first ] )
)