22 lines · 286 B · C
RawDownload
#include <u.h>#include <libc.h>#include <draw.h> /* * check for zero, negative size or insanely huge rectangle. */intbadrect(Rectangle r){	int x, y;	uint z; 	x = Dx(r);	y = Dy(r);	if(x > 0 && y > 0){		z = x*y;		if(z/x == y && z < 0x10000000)			return 0;	}	return 1;}

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t