Home
last modified time | relevance | path

Searched refs:now (Results 1 – 25 of 1616) sorted by relevance

12345678910>>...65

/freebsd/contrib/libarchive/libarchive/test/
H A Dtest_archive_parse_date.c37 time_t now = time(NULL); in DEFINE_TEST() local
39 assertEqualInt(get_date(now, "Jan 1, 1970 UTC"), 0); in DEFINE_TEST()
40 assertEqualInt(get_date(now, "7:12:18-0530 4 May 1983"), 420900138); in DEFINE_TEST()
41 assertEqualInt(get_date(now, "2004/01/29 513 mest"), 1075345980); in DEFINE_TEST()
42 assertEqualInt(get_date(now, "2038-06-01 00:01:02 UTC"), in DEFINE_TEST()
44 assertEqualInt(get_date(now, "99/02/17 7pm utc"), 919278000); in DEFINE_TEST()
45 assertEqualInt(get_date(now, "02/17/99 7:11am est"), 919253460); in DEFINE_TEST()
46 assertEqualInt(get_date(now, "now - 2 hours"), in DEFINE_TEST()
47 get_date(now, "2 hours ago")); in DEFINE_TEST()
48 assertEqualInt(get_date(now, "2 hours ago"), in DEFINE_TEST()
[all …]
/freebsd/crypto/krb5/src/lib/krb5/os/
H A Dc_ustime.c79 struct time_now now; in k5_us_timeofday() local
82 err = get_time_now(&now); in k5_us_timeofday()
86 *seconds = now.sec; in k5_us_timeofday()
87 *microseconds = now.usec; in k5_us_timeofday()
96 struct time_now now; in krb5_crypto_us_timeofday() local
99 now.sec = now.usec = 0; in krb5_crypto_us_timeofday()
100 err = get_time_now(&now); in krb5_crypto_us_timeofday()
123 if (now.sec == ts_incr(last_time.sec, -1) || in krb5_crypto_us_timeofday()
124 (now.sec == last_time.sec && now.usec <= last_time.usec)) { in krb5_crypto_us_timeofday()
130 now.sec = last_time.sec; in krb5_crypto_us_timeofday()
[all …]
/freebsd/contrib/unbound/testcode/
H A Dunitinfra.c51 size_t zonelen, int wr, time_t now, struct infra_key** k) in infra_lookup_host() argument
58 if(d->ttl < now) { in infra_lookup_host()
68 uint8_t* zone, size_t zonelen, time_t *now, int keep_probing, in test_keep_probing() argument
82 *now += cfg->host_ttl + 10; in test_keep_probing()
84 *now, &vs, &edns_lame, &to) ); in test_keep_probing()
89 LDNS_RR_TYPE_A, -1, to, *now) ); in test_keep_probing()
91 *now, &vs, &edns_lame, &to) ); in test_keep_probing()
97 unit_assert( (d=infra_lookup_host(slab, &one, onelen, zone, zonelen, 0, *now, &k)) ); in test_keep_probing()
102 cfg->host_ttl = cfg->host_ttl + *now < probedelay in test_keep_probing()
107 *now = probedelay; in test_keep_probing()
[all …]
H A Dfake_event.c216 if(!runtime->now || runtime->now->evt_type != repevt_back_query in pending_matches_current()
221 if(runtime->now->addrlen != 0 && in pending_matches_current()
222 sockaddr_cmp(&p->addr, p->addrlen, &runtime->now->addr, in pending_matches_current()
223 runtime->now->addrlen) != 0) in pending_matches_current()
225 if((e=find_match(runtime->now->match, p->pkt, p->pkt_len, in pending_matches_current()
246 int timenow = runtime->now->time_step; in pending_find_match()
416 log_assert(runtime && runtime->now && in answer_check_it()
417 runtime->now->evt_type == repevt_front_reply); in answer_check_it()
422 if((runtime->now->addrlen == 0 || sockaddr_cmp( in answer_check_it()
423 &runtime->now->addr, runtime->now->addrlen, in answer_check_it()
[all …]
/freebsd/sys/kern/
H A Dkern_clocksource.c61 static void loadtimer(sbintime_t now, int first);
69 static int handleevents(sbintime_t now, int fake);
116 sbintime_t now; /* Last tick time. */ member
137 sbintime_t now; in hardclockintr() local
144 now = state->now; in hardclockintr()
146 (int)(now >> 32), (u_int)(now & 0xffffffff)); in hardclockintr()
147 done = handleevents(now, 0); in hardclockintr()
155 handleevents(sbintime_t now, int fake) in handleevents() argument
164 (int)(now >> 32), (u_int)(now & 0xffffffff)); in handleevents()
177 while (now >= state->nexthard) { in handleevents()
[all …]
H A Dsubr_filter.c136 check_update_times(struct time_filter *tf, uint64_t value, uint32_t now) in check_update_times() argument
142 tim = now - tf->entries[i].time_up; in check_update_times()
157 tf->entries[i].time_up = now; in check_update_times()
162 tim = now - tf->entries[i].time_up; in check_update_times()
166 tf->entries[i].time_up = now; in check_update_times()
171 check_update_times_small(struct time_filter_small *tf, uint32_t value, uint32_t now) in check_update_times_small() argument
177 tim = now - tf->entries[i].time_up; in check_update_times_small()
192 tf->entries[i].time_up = now; in check_update_times_small()
197 tim = now - tf->entries[i].time_up; in check_update_times_small()
201 tf->entries[i].time_up = now; in check_update_times_small()
[all …]
/freebsd/usr.sbin/fifolog/lib/
H A Dfifolog_write_poll.c45 static int fifolog_write_gzip(struct fifolog_writer *f, time_t now);
104 time_t now; in fifolog_write_close() local
110 time(&now); in fifolog_write_close()
111 fifolog_write_gzip(f, now); in fifolog_write_close()
123 time_t now; in fifolog_write_open() local
172 time(&now); in fifolog_write_open()
173 f->starttime = now; in fifolog_write_open()
174 f->lastsync = now; in fifolog_write_open()
175 f->lastwrite = now; in fifolog_write_open()
187 fifolog_write_output(struct fifolog_writer *f, int fl, time_t now) in fifolog_write_output() argument
[all …]
/freebsd/contrib/ntp/ntpd/
H A Dntp_util.c368 l_fp now; in stats_config()
539 get_systime(&now); in stats_config()
546 leapsec_expired(now.l_ui, NULL) in stats_config()
556 check_leap_expiration(TRUE, now.l_ui, &ttnow); in stats_config()
590 l_fp now; in record_peer_stats() local
596 get_systime(&now); in record_peer_stats()
597 filegen_setup(&peerstats, now.l_ui); in record_peer_stats()
601 day = now.l_ui / 86400 + MJD_1900; in record_peer_stats()
602 now.l_ui %= 86400; in record_peer_stats()
605 ulfptoa(&now, in record_peer_stats()
363 l_fp now; stats_config() local
631 l_fp now; record_loop_stats() local
665 l_fp now; record_clock_stats() local
740 l_fp now; record_raw_stats() local
801 l_fp now; record_sys_stats() local
838 l_fp now; record_proto_stats() local
872 l_fp now; record_crypto_stats() local
910 l_fp now; record_timing_stats() local
[all...]
/freebsd/contrib/kyua/utils/signals/
H A Dtimer.cpp164 const datetime::timestamp& now, in compute_timers_to_run_and_prune_old() argument
170 while (iter != _all_timers.end() && (*iter).first <= now) { in compute_timers_to_run_and_prune_old()
192 const datetime::timestamp& now, in reprogram_system_timer() argument
211 while (next < now) { in reprogram_system_timer()
222 if (next < _timer_activation || now > _timer_activation) { in reprogram_system_timer()
223 INV(next >= now); in reprogram_system_timer()
224 const datetime::delta delta = next - now; in reprogram_system_timer()
225 LD(F("Reprogramming timer; firing on %s; now is %s") % next % now); in reprogram_system_timer()
242 global_state(signals::timer* timer, const datetime::timestamp& now) : in global_state() argument
245 PRE(now < timer->when()); in global_state()
[all …]
/freebsd/contrib/sendmail/libsm/
H A Dclock.c95 auto struct timeval now, nowi, ival; local
98 auto time_t now, nowi; local
110 (void) gettimeofday(&now, NULL);
111 nowi = now;
112 timeradd(&now, &ival, &nowi);
114 now = time(NULL);
115 nowi = now + (time_t)(intvl / 1000);
166 timersub(&SmEventQueue->ev_time, &now, &itime.it_value);
175 intvl = SmEventQueue->ev_time - now;
327 struct timeval now; local
[all …]
/freebsd/contrib/netbsd-tests/lib/libutil/
H A Dt_parsedate.c239 time_t now; in ATF_TC_BODY() local
241 #define REL_CHECK(s, now, tm) do { \ in ATF_TC_BODY() argument
244 p = parsedate(s, &now, NULL); \ in ATF_TC_BODY()
248 (uintmax_t)now, ctime_r(&now, nb), \ in ATF_TC_BODY()
269 for (now = 0x00FFFFFF; now < 0xFF000000; now += 3777779) { in ATF_TC_BODY()
270 ATF_CHECK(localtime_r(&now, &tm) != NULL); in ATF_TC_BODY()
274 REL_CHECK("yesterday", now, tm); in ATF_TC_BODY()
276 ATF_CHECK(localtime_r(&now, &tm) != NULL); in ATF_TC_BODY()
280 REL_CHECK("tomorrow", now, tm); in ATF_TC_BODY()
282 ATF_CHECK(localtime_r(&now, &tm) != NULL); in ATF_TC_BODY()
[all …]
/freebsd/sys/contrib/openzfs/include/os/linux/zfs/sys/
H A Dtrace_zio.h43 TP_PROTO(zio_t *zio, hrtime_t now),
44 TP_ARGS(zio, now),
47 __field(hrtime_t, now)
51 __entry->now = now;
53 TP_printk("now %llu " ZIO_TP_PRINTK_FMT, __entry->now,
58 TP_PROTO(zio_t *zio, hrtime_t now, hrtime_t diff),
59 TP_ARGS(zio, now, diff),
62 __field(hrtime_t, now)
67 __entry->now = now;
70 TP_printk("now %llu diff %llu " ZIO_TP_PRINTK_FMT, __entry->now,
/freebsd/contrib/unbound/services/cache/
H A Ddns.c61 * @param now: current time.
72 * earlier than the time in now. The time is used to determine if RRsets
78 store_rrsets(struct module_env* env, struct reply_info* rep, time_t now, in store_rrsets() argument
91 LDNS_RR_TYPE_NS && !pside)?qstarttime:now) + leeway)) { in store_rrsets()
103 rep->ref[i].key, region, now); in store_rrsets()
172 reply_info_set_ttls(rep, *env->now); in dns_cache_store_msg()
173 store_rrsets(env, rep, *env->now, leeway, pside, qrep, region, in dns_cache_store_msg()
209 uint16_t qclass, time_t now, uint16_t searchtype, int stripfront, in find_closest_of_type() argument
225 qnamelen, searchtype, qclass, 0, now, 0))) { in find_closest_of_type()
244 &qnamelen, searchtype, qclass, now, expireto in find_closest_of_type()
271 addr_to_additional(struct ub_packed_rrset_key * rrset,struct regional * region,struct dns_msg * msg,time_t now) addr_to_additional() argument
283 msg_cache_lookup(struct module_env * env,uint8_t * qname,size_t qnamelen,uint16_t qtype,uint16_t qclass,uint16_t flags,time_t now,int wr) msg_cache_lookup() argument
308 find_add_addrs(struct module_env * env,uint16_t qclass,struct regional * region,struct delegpt * dp,time_t now,struct dns_msg ** msg) find_add_addrs() argument
374 time_t now = *env->now; cache_fill_missing() local
435 find_add_ds(struct module_env * env,struct regional * region,struct dns_msg * msg,struct delegpt * dp,time_t now) find_add_ds() argument
501 dns_msg_authadd(struct dns_msg * msg,struct regional * region,struct ub_packed_rrset_key * rrset,time_t now) dns_msg_authadd() argument
512 dns_msg_ansadd(struct dns_msg * msg,struct regional * region,struct ub_packed_rrset_key * rrset,time_t now) dns_msg_ansadd() argument
524 dns_cache_find_delegation(struct module_env * env,uint8_t * qname,size_t qnamelen,uint16_t qtype,uint16_t qclass,struct regional * region,struct dns_msg ** msg,time_t now,int noexpiredabove,uint8_t * expiretop,size_t expiretoplen) dns_cache_find_delegation() argument
602 tomsg(struct module_env * env,struct query_info * q,struct reply_info * r,struct regional * region,time_t now,int allow_expired,struct regional * scratch) tomsg() argument
699 rrset_msg(struct ub_packed_rrset_key * rrset,struct regional * region,time_t now,struct query_info * q) rrset_msg() argument
731 synth_dname_msg(struct ub_packed_rrset_key * rrset,struct regional * region,time_t now,struct query_info * q,enum sec_status * sec_status) synth_dname_msg() argument
829 time_t now = *env->now; fill_any() local
898 time_t now = *env->now; dns_cache_lookup() local
[all...]
/freebsd/sys/x86/x86/
H A Ddelay.c53 uint64_t end, now; in delay_tsc() local
60 now = rdtsc(); in delay_tsc()
61 end = now + tsc_freq * n / 1000000; in delay_tsc()
64 now = rdtsc(); in delay_tsc()
65 } while (now < end); in delay_tsc()
74 uint64_t end, freq, now; in delay_tc() local
93 now = 0; in delay_tc()
100 now += mask - last + u + 1; in delay_tc()
102 now += u - last; in delay_tc()
104 } while (now < end); in delay_tc()
/freebsd/contrib/pam-krb5/tests/module/
H A Dexpired-t.c38 time_t now; in main() local
51 now = time(NULL) - 1; in main()
52 if (!kerberos_expire_password(krbconf->userprinc, now)) in main()
54 date = bstrdup(ctime(&now)); in main()
90 kerberos_expire_password(krbconf->userprinc, now); in main()
96 kerberos_expire_password(krbconf->userprinc, now); in main()
103 kerberos_expire_password(krbconf->userprinc, now); in main()
111 kerberos_expire_password(krbconf->userprinc, now); in main()
115 kerberos_expire_password(krbconf->userprinc, now); in main()
120 kerberos_expire_password(krbconf->userprinc, now); in main()
[all …]
/freebsd/sys/netpfil/ipfw/
H A Ddn_sched_fq_codel_helper.h51 fqc_dodequeue(struct fq_codel_flow *q, aqm_time_t now, uint16_t *ok_to_drop, in fqc_dodequeue() argument
80 sojourn_time = now - pkt_ts; in fqc_dodequeue()
88 q->cst.first_above_time = now + schk->cfg.ccfg.interval; in fqc_dodequeue()
89 } else if (now >= q->cst.first_above_time) { in fqc_dodequeue()
103 aqm_time_t now; in fqc_codel_dequeue() local
110 now = AQM_UNOW; in fqc_codel_dequeue()
111 m = fqc_dodequeue(q, now, &ok_to_drop, si); in fqc_codel_dequeue()
125 while (now >= cst->drop_next_time && cst->dropping) { in fqc_codel_dequeue()
137 m = fqc_dodequeue(q, now, &ok_to_drop, si); in fqc_codel_dequeue()
159 m = fqc_dodequeue(q, now, &ok_to_drop,si); in fqc_codel_dequeue()
[all …]
H A Ddn_aqm_codel.h79 codel_dodequeue(struct dn_queue *q, aqm_time_t now, uint16_t *ok_to_drop) in codel_dodequeue() argument
112 sojourn_time = now - pkt_ts; in codel_dodequeue()
120 cst->first_above_time = now + cprms->interval; in codel_dodequeue()
121 } else if (now >= cst->first_above_time) { in codel_dodequeue()
137 aqm_time_t now; in codel_dequeue() local
142 now = AQM_UNOW; in codel_dequeue()
144 m = codel_dodequeue(q, now, &ok_to_drop); in codel_dequeue()
157 while (now >= cst->drop_next_time && cst->dropping) { in codel_dequeue()
170 m = codel_dodequeue(q, now, &ok_to_drop); in codel_dequeue()
193 m = codel_dodequeue(q, now, &ok_to_drop); in codel_dequeue()
[all …]
/freebsd/sys/sys/
H A Dtim_filter.h86 void tick_filter_clock(struct time_filter *tf, uint32_t now);
87 uint32_t apply_filter_min(struct time_filter *tf, uint64_t value, uint32_t now);
88 uint32_t apply_filter_max(struct time_filter *tf, uint64_t value, uint32_t now);
89 void filter_reduce_by(struct time_filter *tf, uint64_t reduce_by, uint32_t now);
90 void filter_increase_by(struct time_filter *tf, uint64_t incr_by, uint32_t now);
108 void tick_filter_clock_small(struct time_filter_small *tf, uint32_t now);
110 uint32_t value, uint32_t now);
112 uint32_t value, uint32_t now);
114 uint32_t reduce_by, uint32_t now);
116 uint32_t incr_by, uint32_t now);
/freebsd/crypto/openssl/crypto/
H A Dsleep.c115 OSSL_TIME now = ossl_time_now(); in OSSL_sleep() local
116 OSSL_TIME finish = ossl_time_add(now, ossl_ms2time(millis)); in OSSL_sleep()
122 now = ossl_time_now(); in OSSL_sleep()
123 left = ossl_time2ms(ossl_time_subtract(finish, now)); in OSSL_sleep()
124 } while (ossl_time_compare(now, finish) < 0 && left > 1000); in OSSL_sleep()
126 if (ossl_time_compare(now, finish) >= 0) in OSSL_sleep()
132 now = ossl_time_now(); in OSSL_sleep()
133 left = ossl_time2ms(ossl_time_subtract(finish, now)); in OSSL_sleep()
134 } while (ossl_time_compare(now, finish) < 0); in OSSL_sleep()
/freebsd/stand/i386/libi386/
H A Dtime.c71 time_t now, check; in time() local
77 now = check; in time()
79 if (check != now) in time()
83 if (now < lasttime) in time()
84 now += 24 * 3600; in time()
85 lasttime = now; in time()
88 *t = now; in time()
89 return(now); in time()
/freebsd/usr.sbin/efiwake/
H A Defiwake.c54 struct efi_tm now; in main() local
96 error = ioctl(efi_fd, EFIIOC_GET_TIME, &now); in main()
102 now.tm_year, now.tm_mon, now.tm_mday, now.tm_hour, now.tm_min, in main()
103 now.tm_sec); in main()
113 waketime.waketime = now; in main()
/freebsd/contrib/openpam/lib/libpam/
H A Dopenpam_ttyconv.c87 struct timeval now, target, remaining; in prompt_tty() local
127 (void)gettimeofday(&now, NULL); in prompt_tty()
130 timeradd(&now, &remaining, &target); in prompt_tty()
133 now.tv_sec = now.tv_usec = 0; in prompt_tty()
147 gettimeofday(&now, NULL); in prompt_tty()
148 if (timercmp(&now, &target, >)) in prompt_tty()
150 timersub(&target, &now, &remaining); in prompt_tty()
216 struct timeval now, target, remaining; in prompt_notty() local
227 (void)gettimeofday(&now, NULL); in prompt_notty()
230 timeradd(&now, &remaining, &target); in prompt_notty()
[all …]
/freebsd/crypto/openssh/
H A Dsrclimit.c215 expire_penalties_from_tree(time_t now, const char *t, in expire_penalties_from_tree() argument
223 if (penalty->expiry >= now) in expire_penalties_from_tree()
237 expire_penalties(time_t now) in expire_penalties() argument
239 expire_penalties_from_tree(now, "ipv4", in expire_penalties()
241 expire_penalties_from_tree(now, "ipv6", in expire_penalties()
263 time_t now; in srclimit_penalty_check_allow() local
280 now = monotime(); in srclimit_penalty_check_allow()
281 expire_penalties(now); in srclimit_penalty_check_allow()
300 if (penalty->expiry < now) { in srclimit_penalty_check_allow()
301 expire_penalties(now); in srclimit_penalty_check_allow()
[all …]
/freebsd/sys/contrib/libsodium/
H A DChangeLog3 - Signatures computations and verifications are now way faster on
12 `crypto_sign_edwards25519sha512batch_open` now reject public keys in
16 - Webassembly: `crypto_pwhash_*()` functions are now included in
21 - The Salsa20-based PRNG example is now thread-safe on platforms with
28 - The default password hashing algorithm is now Argon2id. The
39 module now returns a `.ready` promise that will resolve after the
45 - iOS binaries should now be compatible with WatchOS and TVOS.
46 - WebAssembly is now officially supported. Special thanks to
62 - crypto_sign_ed25519_pk_to_curve25519() now rejects points that are
66 - Visual Studio solutions are now included in distribution tarballs.
[all …]
/freebsd/contrib/flex/
H A DNEWS7 *** The indent target now knows about flex's new (as of 2.6.0)
11 *** The files included in the flex distribution are now built by the
20 we now check for how to call libtoolize and use what we find in
49 *** All scripts in the test suite are now run by $(SHELL) and the
55 *** Tests that depend on platform dependent features now properly skip
58 *** When running "make check", you can now pas V=0 to silence more of
87 *** It is now possible to build flex without building the accompanying
109 *** flex should now handle quoting when mixed with m4 processing correctly
121 *** input filenames on MSWindows are now calculated correctly
123 *** general code cleanups in a number of tests now make the test suite compile much more cleanly
[all …]

12345678910>>...65