fix(scheduler): downgrade routine EEXIST resync log, dedup hash_string
xce_core_push_events() WARNed on every JOBS_PUSH resync redelivery (sched_add_job rc=-EEXIST), which is the expected outcome under on_scheduler_join()'s full resync or the array-push dedup race (bug-1734/bug-1714) and flooded operational logs. Only that case now logs via a new DBG() macro (utils.h); any other add_rc (e.g. -ENOMEM) still WARNs. DBG is named to avoid colliding with the build's own -DDEBUG command-line define (debug/asan buildtypes). Also collapsed hash_string()'s duplicated djb2 loop to delegate to hash_block(), which already implements the same RUN_HASH loop. Logged as bug-1809 in .wolf/buglog.json. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01RLSNJhNoULvVcUhXEFafQC
This commit is contained in:
parent
868c6427c8
commit
b7250c2ec6
7 changed files with 115 additions and 19 deletions
|
|
@ -802,12 +802,5 @@ uint32_t hash_block(char* buf, size_t len)
|
|||
|
||||
uint32_t hash_string(const char* key)
|
||||
{
|
||||
uint32_t hc = 5381;
|
||||
int c;
|
||||
|
||||
while ((c = *key++)) {
|
||||
hc = RUN_HASH(hc, c);
|
||||
}
|
||||
|
||||
return hc;
|
||||
return hash_block((char*)key, strlen(key));
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue