Šī lapa labāk darbojas, ja pārlūkam ir iespējots JavaScript.
Sākums
Izpētīt
lain.church
Palīdzība
Reģistrēties
Pierakstīties
izaya
/
OC-PsychOS2
spogulis no
https://git.shadowkat.net/izaya/OC-PsychOS2.git
Vērot
1
Pievienot zvaigznīti
1
Atdalīts
0
Kods
Problēmas
0
Laidieni
0
Vikivietne
Aktivitāte
Pārlūkot izejas kodu
fix edge case where io.open(whatever):read() returns nil
master
XeonSquared
pirms 10 mēnešiem
vecāks
c2bbd7d2ca
revīzija
a33476cf00
1 mainītis faili
ar
1 papildinājumiem
un
1 dzēšanām
Dalītais skats
Salīdzināšanas iespējas
Rādīt statistiku
Lejupielādēt ielāpa failu
Lejupielādēt izmaiņu failu
+1
-1
lib/libmtar.lua
+ 1
- 1
lib/libmtar.lua
Parādīt failu
@@ -24,7 +24,7 @@ end
function mtar.iter(stream) -- table -- function -- Given buffer *stream*, returns an iterator suitable for use with *for* that returns, for each iteration, the file name, a function to read from the file, and the length of the file.
local remain = 0
local function read(n)
local rb = stream:read(math.min(n,remain))
local rb = stream:read(math.min(n,remain))
or ""
remain = remain - rb:len()
return rb
end
Rakstīt
Priekšskatītījums
Notiek ielāde…
Atcelt
Saglabāt