interplane.Get Omega
Read in your language

omega-mv

Omega: a language for verified programs, semantic identity and machine realization. Seed-born work and existing implementations have distinct provenance.

Brought by drakestapleton

branch main Branches Tags History

omega-mv / seed / omc / sites / found-s-assign-1.om

33 lines · 629 bytes Raw Blame History
1note sites: found by a one-token change of a tracked program; reaches the omc error site in s-assign (code 7)
2note chown: fchownat to the current uid (gid unchanged); st_uid low byte at 24, missing path errno.
3text p "own.tmp"
4text miss "no.such.file"
5fn main to int
6fd = int fopen p 0 len p 578 420
7if lt fd 0
8ret 1
9end
10r f32 fclose fd
11u = getuid
12r = chown p 0 len p int u int -1
13if ne r 0
14ret 2
15end
16st = new uchar 128 0
17r = stat p 0 len p st 0 128
18if ne r 0
19ret 3
20end
21if ne int get st 24 int and u long 255
22ret 4
23end
24r = chown miss 0 len miss int u int -1
25if ge r 0
26ret 5
27end
28r = unlink p 0 len p
29if ne r 0
30ret 6
31end
32ret 0
33end