diff options
| author | fusion32 <marcopuzziello@gmail.com> | 2025-10-16 04:23:52 -0300 |
|---|---|---|
| committer | fusion32 <marcopuzziello@gmail.com> | 2025-10-16 04:23:52 -0300 |
| commit | 01a6e8dbe42fb6571ad846bee5e1d8cc7c9fba5e (patch) | |
| tree | cccdd754cb6c428ab0e3c3b6a8d0cd1003ff43b0 /src/hostcache.cc | |
| parent | 9825f08f2b46b147faa48e4d127c93694522e6d6 (diff) | |
| download | querymanager-01a6e8dbe42fb6571ad846bee5e1d8cc7c9fba5e.tar.gz querymanager-01a6e8dbe42fb6571ad846bee5e1d8cc7c9fba5e.zip | |
move ResolveHostName outside of GetCharacterEndpoints
Diffstat (limited to 'src/hostcache.cc')
| -rw-r--r-- | src/hostcache.cc | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/hostcache.cc b/src/hostcache.cc index 23be08f..9fda094 100644 --- a/src/hostcache.cc +++ b/src/hostcache.cc @@ -58,7 +58,10 @@ static bool DoResolveHostName(const char *HostName, int *OutAddr){ } bool ResolveHostName(const char *HostName, int *OutAddr){ - ASSERT(HostName != NULL && !StringEmpty(HostName)); + if(HostName == NULL || StringEmpty(HostName)){ + return false; + } + THostCacheEntry *Entry = NULL; int LeastRecentlyUsedIndex = 0; int LeastRecentlyUsedTime = g_CachedHostNames[0].ResolveTime; |
