~ft/neindaw

8747033fb429a67053e229b30c323ce1c5a25a54 — Sigrid Solveig Haflínudóttir 8 months ago 655a565
fix a warning on 386
1 files changed, 4 insertions(+), 3 deletions(-)

M util.c
M util.c => util.c +4 -3
@@ 70,15 70,16 @@ nanosec(void)
		return nsec() - xstart;

	if(fasthz == 0){
		if((fasthz = _tos->cyclefreq) == 0){
		fasthz = _tos->cyclefreq;
		if(fasthz == 0){
			fasthz = ~0ULL;
			xstart = nsec();
			fprint(2, "cyclefreq not available, falling back to nsec()\n");
			fprint(2, "you might want to disable aux/timesync\n");
			return 0;
		}else{
			cycles(&xstart);
		}
		cycles(&xstart);
		return 0;
	}
	cycles(&x);
	x -= xstart;