projects
/
super-star-trek.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
18e7452
)
better fix for is_valid()
author
Stas Sergeev
<stsp@aknet.ru>
Tue, 26 Sep 2006 17:46:57 +0000
(17:46 +0000)
committer
Stas Sergeev
<stsp@aknet.ru>
Tue, 26 Sep 2006 17:46:57 +0000
(17:46 +0000)
src/sst.h
patch
|
blob
|
history
diff --git
a/src/sst.h
b/src/sst.h
index fbaa466f42a05eda0d0dc401d884e1fecf3479a8..f9676f83cb2813eadf7468594a8e6611c69f6fcb 100644
(file)
--- a/
src/sst.h
+++ b/
src/sst.h
@@
-46,7
+46,7
@@
typedef struct {int x; int y;} coord;
#define same(c1, c2) ((c1.x == c2.x) && (c1.y == c2.y))
#define distance(c1, c2) sqrt(square(c1.x - c2.x) + square(c1.y - c2.y))
#define invalidate(w) w.x = w.y = 0
-#define is_valid(w) (w.x != 0
||
w.y != 0)
+#define is_valid(w) (w.x != 0
&&
w.y != 0)
typedef struct {
coord w;