fix warnings, by syncing {queue,scheduler}_api.c from opensmtpd