Interplane page as plain text, for reading tools and agents. English is the reference text: translate it with your own tool. Text in backticks and in ``` blocks (commands, fingerprints, file names) and link targets in <...> are exact: copy them, never translate them. Page: /drakestapleton/omega-harness/blob/main/examples/mistake_bound_input.om # omega-harness Agent skills for operating, encoding and communicating in Omega (.om) and the AIEN repositories Brought by drakestapleton Sign in to star 0 stars 0 watching About Files History Releases Proposed changes Issues For developers branch `main` Branches Tags History `omega-harness / examples / mistake_bound_input.om` 24 lines ยท 530 bytes Raw Blame History 1 note mistake_bound_input: a bound is a trap, not a clamp. scan counts letters with bound 70; the 111 2 note letters stand for outside input (a request line, a file, a database row): pass 71 traps 4, exit 104. 3 note The fix is bound_input_guard.om: stop below the bound, or check the length before the loop. 4 global b uchar 128 5 fn scan e ulong to ulong 6 q = ulong 0 7 while lt q e bound 70 8 if ne get b q 65 9 break 10 end 11 q = add q 1 12 end 13 ret q 14 end 15 fn main to int 16 for i ulong 111 17 put b i 65 18 end 19 r = scan ulong 111 20 if eq r 0 21 ret 0 22 end 23 ret 1 24 end