1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-05-20 14:35:07 +00:00
serenity/Userland/Utilities
Andreas Kling d88c7fee32 LibGfx+Userland: Make PNGWriter::encode() return ErrorOr<ByteBuffer>
This is a first step towards handling PNG encoding failures instead of
just falling over and crashing the program.

This initial step will cause encode() to return an error if the final
ByteBuffer copy fails to allocate. There are more potential failures
that will be surfaced by subsequent commits.

Two FIXMEs were killed in the making of this patch. :^)
2022-12-08 13:01:11 +00:00
..
abench.cpp Everywhere: Add sv suffix to strings relying on StringView(char const*) 2022-07-12 23:11:35 +02:00
adjtime.cpp Userland: Remove unecessary uses of __serenity__ macro 2022-10-10 12:23:12 +02:00
allocate.cpp AK+Everywhere: Rename String to DeprecatedString 2022-12-06 08:54:33 +01:00
aplay.cpp aplay: Preload more audio 2022-11-25 17:01:44 -07:00
arp.cpp Everywhere: Rename to_{string => deprecated_string}() where applicable 2022-12-06 08:54:33 +01:00
asctl.cpp AK+Everywhere: Rename String to DeprecatedString 2022-12-06 08:54:33 +01:00
base64.cpp base64: Port to Core::Stream 2022-11-19 17:00:10 +00:00
basename.cpp Everywhere: Use default execpromises argument for Core::System::pledge 2021-11-28 08:04:57 +01:00
beep.cpp beep: Port to LibMain :^) 2022-01-09 11:16:00 +03:30
blockdev.cpp Everywhere: Run clang-format 2022-04-01 21:24:45 +01:00
bt.cpp AK+Everywhere: Rename String to DeprecatedString 2022-12-06 08:54:33 +01:00
cal.cpp Everywhere: Run clang-format 2022-04-01 21:24:45 +01:00
cat.cpp cat: Return a non-null value if an error occurred 2022-11-24 21:01:54 -05:00
checksum.cpp Everywhere: Rename to_{string => deprecated_string}() where applicable 2022-12-06 08:54:33 +01:00
chgrp.cpp AK+Everywhere: Rename String to DeprecatedString 2022-12-06 08:54:33 +01:00
chmod.cpp chmod: Implement the --recursive flag 2022-07-25 15:32:46 +02:00
chown.cpp AK+Everywhere: Rename String to DeprecatedString 2022-12-06 08:54:33 +01:00
chres.cpp Userland: Always construct Application with try_create() 2022-04-18 12:57:34 +02:00
cksum.cpp AK+Everywhere: Rename String to DeprecatedString 2022-12-06 08:54:33 +01:00
clear.cpp Utilities: Use default execpromises parameter to pledge(..) 2022-04-03 17:13:51 -07:00
CMakeLists.txt Utilities: Add strings 2022-12-04 12:08:48 +00:00
cmp.cpp AK+Everywhere: Rename String to DeprecatedString 2022-12-06 08:54:33 +01:00
comm.cpp AK+Everywhere: Rename String to DeprecatedString 2022-12-06 08:54:33 +01:00
config.cpp AK+Everywhere: Rename String to DeprecatedString 2022-12-06 08:54:33 +01:00
copy.cpp Everywhere: Rename to_{string => deprecated_string}() where applicable 2022-12-06 08:54:33 +01:00
cp.cpp AK+Everywhere: Rename String to DeprecatedString 2022-12-06 08:54:33 +01:00
cpp-lexer.cpp Everywhere: Rename to_{string => deprecated_string}() where applicable 2022-12-06 08:54:33 +01:00
cpp-parser.cpp Utilities: Port cpp utilities to Core::Stream 2022-11-19 17:00:10 +00:00
cpp-preprocessor.cpp Everywhere: Rename to_{string => deprecated_string}() where applicable 2022-12-06 08:54:33 +01:00
cut.cpp AK+Everywhere: Rename String to DeprecatedString 2022-12-06 08:54:33 +01:00
date.cpp Everywhere: Rename to_{string => deprecated_string}() where applicable 2022-12-06 08:54:33 +01:00
dd.cpp Everywhere: Rename to_{string => deprecated_string}() where applicable 2022-12-06 08:54:33 +01:00
df.cpp Everywhere: Rename to_{string => deprecated_string}() where applicable 2022-12-06 08:54:33 +01:00
diff.cpp AK+Everywhere: Rename String to DeprecatedString 2022-12-06 08:54:33 +01:00
dirname.cpp AK+Everywhere: Rename String to DeprecatedString 2022-12-06 08:54:33 +01:00
disasm.cpp Everywhere: Rename to_{string => deprecated_string}() where applicable 2022-12-06 08:54:33 +01:00
disk_benchmark.cpp AK+Everywhere: Rename String to DeprecatedString 2022-12-06 08:54:33 +01:00
dmesg.cpp dmesg: Port to Core::Stream 2022-11-19 17:00:10 +00:00
du.cpp Everywhere: Rename to_{string => deprecated_string}() where applicable 2022-12-06 08:54:33 +01:00
echo.cpp AK+Everywhere: Rename String to DeprecatedString 2022-12-06 08:54:33 +01:00
env.cpp AK+Everywhere: Rename String to DeprecatedString 2022-12-06 08:54:33 +01:00
errno.cpp AK+Everywhere: Rename String to DeprecatedString 2022-12-06 08:54:33 +01:00
expr.cpp AK+Everywhere: Rename String to DeprecatedString 2022-12-06 08:54:33 +01:00
false.cpp false: Port to LibMain 2022-01-14 19:42:19 +02:00
fdtdump.cpp AK+Everywhere: Rename String to DeprecatedString 2022-12-06 08:54:33 +01:00
fgrep.cpp Everywhere: Rename to_{string => deprecated_string}() where applicable 2022-12-06 08:54:33 +01:00
file.cpp AK+Everywhere: Rename String to DeprecatedString 2022-12-06 08:54:33 +01:00
find.cpp AK+Everywhere: Rename String to DeprecatedString 2022-12-06 08:54:33 +01:00
flock.cpp LibCore+flock: Make Core::System::waitpid more ergonomic 2022-01-11 16:04:29 +01:00
fortune.cpp Everywhere: Rename to_{string => deprecated_string}() where applicable 2022-12-06 08:54:33 +01:00
functrace.cpp AK+Everywhere: Rename String to DeprecatedString 2022-12-06 08:54:33 +01:00
gml-format.cpp AK+Everywhere: Rename String to DeprecatedString 2022-12-06 08:54:33 +01:00
grep.cpp Everywhere: Rename to_{string => deprecated_string}() where applicable 2022-12-06 08:54:33 +01:00
gron.cpp AK+Everywhere: Rename String to DeprecatedString 2022-12-06 08:54:33 +01:00
groupadd.cpp Everywhere: Use my fairly new and shiny serenityos.org email :^) 2022-06-30 15:59:42 +01:00
groupdel.cpp Everywhere: Explicitly specify the size in StringView constructors 2022-07-12 23:11:35 +02:00
groups.cpp AK+Everywhere: Rename String to DeprecatedString 2022-12-06 08:54:33 +01:00
gunzip.cpp AK+Everywhere: Rename String to DeprecatedString 2022-12-06 08:54:33 +01:00
gzip.cpp AK+Everywhere: Rename String to DeprecatedString 2022-12-06 08:54:33 +01:00
head.cpp AK+Everywhere: Rename String to DeprecatedString 2022-12-06 08:54:33 +01:00
headless-browser.cpp LibGfx+Userland: Make PNGWriter::encode() return ErrorOr<ByteBuffer> 2022-12-08 13:01:11 +00:00
hello-world.jakt Meta+Userland: Add jakt as an optional Lagom Tool 2022-05-23 23:05:45 +02:00
hexdump.cpp hexdump: Replace Core::File with Core::Stream::File 2022-11-26 11:07:00 +01:00
host.cpp AK+Everywhere: Rename String to DeprecatedString 2022-12-06 08:54:33 +01:00
hostname.cpp Userland: Convert command line arguments to String/StringView 2022-07-12 23:11:35 +02:00
id.cpp AK+Everywhere: Rename String to DeprecatedString 2022-12-06 08:54:33 +01:00
ifconfig.cpp Everywhere: Rename to_{string => deprecated_string}() where applicable 2022-12-06 08:54:33 +01:00
ini.cpp AK+Everywhere: Rename String to DeprecatedString 2022-12-06 08:54:33 +01:00
install.cpp AK+Everywhere: Rename String to DeprecatedString 2022-12-06 08:54:33 +01:00
jail-attach.cpp Userland: Enhance jail-attach utility to support existing and new jails 2022-11-26 01:47:50 -07:00
jail-create.cpp Userland: Add support for jails 2022-11-05 18:00:58 -06:00
js.cpp LibJS: Replace standalone js_string() with PrimitiveString::create() 2022-12-07 16:43:06 +00:00
json.cpp Everywhere: Rename to_{string => deprecated_string}() where applicable 2022-12-06 08:54:33 +01:00
kcov-example.cpp Everywhere: Add sv suffix to strings relying on StringView(char const*) 2022-07-12 23:11:35 +02:00
keymap.cpp AK+Everywhere: Rename String to DeprecatedString 2022-12-06 08:54:33 +01:00
kill.cpp AK+Everywhere: Rename String to DeprecatedString 2022-12-06 08:54:33 +01:00
killall.cpp AK+Everywhere: Rename String to DeprecatedString 2022-12-06 08:54:33 +01:00
less.cpp AK+Everywhere: Rename String to DeprecatedString 2022-12-06 08:54:33 +01:00
ln.cpp AK+Everywhere: Rename String to DeprecatedString 2022-12-06 08:54:33 +01:00
logout.cpp Utilities: Use new global variables at /sys/kernel/ directory 2022-10-25 15:33:34 -06:00
ls.cpp Everywhere: Rename to_{string => deprecated_string}() where applicable 2022-12-06 08:54:33 +01:00
lsblk.cpp AK+Everywhere: Rename String to DeprecatedString 2022-12-06 08:54:33 +01:00
lscpu.cpp lscpu: Port to Core::Stream 2022-11-19 17:00:10 +00:00
lsirq.cpp Everywhere: Rename to_{string => deprecated_string}() where applicable 2022-12-06 08:54:33 +01:00
lsjails.cpp Everywhere: Rename to_{string => deprecated_string}() where applicable 2022-12-06 08:54:33 +01:00
lsof.cpp Everywhere: Rename to_{string => deprecated_string}() where applicable 2022-12-06 08:54:33 +01:00
lspci.cpp AK+Everywhere: Rename String to DeprecatedString 2022-12-06 08:54:33 +01:00
lsusb.cpp AK+Everywhere: Rename String to DeprecatedString 2022-12-06 08:54:33 +01:00
man.cpp AK+Everywhere: Rename String to DeprecatedString 2022-12-06 08:54:33 +01:00
markdown-check.cpp AK+Everywhere: Rename String to DeprecatedString 2022-12-06 08:54:33 +01:00
matroska.cpp Everywhere: Rename to_{string => deprecated_string}() where applicable 2022-12-06 08:54:33 +01:00
md.cpp AK+Everywhere: Rename String to DeprecatedString 2022-12-06 08:54:33 +01:00
mkdir.cpp AK+Everywhere: Rename String to DeprecatedString 2022-12-06 08:54:33 +01:00
mkfifo.cpp AK+Everywhere: Rename String to DeprecatedString 2022-12-06 08:54:33 +01:00
mknod.cpp mknod: Port to LibMain 2022-01-24 14:01:58 +03:30
mktemp.cpp Everywhere: Rename to_{string => deprecated_string}() where applicable 2022-12-06 08:54:33 +01:00
mount.cpp Everywhere: Rename to_{string => deprecated_string}() where applicable 2022-12-06 08:54:33 +01:00
mv.cpp AK+Everywhere: Rename String to DeprecatedString 2022-12-06 08:54:33 +01:00
nc.cpp Everywhere: Run clang-format 2022-04-01 21:24:45 +01:00
netstat.cpp Everywhere: Rename to_{string => deprecated_string}() where applicable 2022-12-06 08:54:33 +01:00
nl.cpp AK+Everywhere: Rename String to DeprecatedString 2022-12-06 08:54:33 +01:00
nologin.cpp nologin: Use proper format strings with out() and outln() 2022-10-31 11:22:39 -04:00
notify.cpp Userland: Convert command line arguments to String/StringView 2022-07-12 23:11:35 +02:00
nproc.cpp nproc: Port to Core::Stream 2022-11-19 17:00:10 +00:00
ntpquery.cpp AK+Everywhere: Rename String to DeprecatedString 2022-12-06 08:54:33 +01:00
open.cpp open: Use more StringView instead of const char* 2022-01-31 15:25:07 +01:00
passwd.cpp AK+Everywhere: Rename String to DeprecatedString 2022-12-06 08:54:33 +01:00
paste.cpp AK+Everywhere: Rename String to DeprecatedString 2022-12-06 08:54:33 +01:00
pathchk.cpp AK+Everywhere: Rename String to DeprecatedString 2022-12-06 08:54:33 +01:00
pgrep.cpp Utilities: Use new global variables at /sys/kernel/ directory 2022-10-25 15:33:34 -06:00
pidof.cpp AK+Everywhere: Rename String to DeprecatedString 2022-12-06 08:54:33 +01:00
ping.cpp Everywhere: Run clang-format 2022-04-01 21:24:45 +01:00
pkill.cpp Utilities: Use new global variables at /sys/kernel/ directory 2022-10-25 15:33:34 -06:00
pledge.cpp AK+Everywhere: Rename String to DeprecatedString 2022-12-06 08:54:33 +01:00
pls.cpp Userland/pls: Use Core::System::exec_command method to execute a command 2022-11-05 18:00:58 -06:00
pmap.cpp Everywhere: Rename to_{string => deprecated_string}() where applicable 2022-12-06 08:54:33 +01:00
pmemdump.cpp AK+Everywhere: Rename String to DeprecatedString 2022-12-06 08:54:33 +01:00
printf.cpp AK+Everywhere: Rename String to DeprecatedString 2022-12-06 08:54:33 +01:00
pro.cpp AK+Everywhere: Rename String to DeprecatedString 2022-12-06 08:54:33 +01:00
profile.cpp AK+Everywhere: Rename String to DeprecatedString 2022-12-06 08:54:33 +01:00
ps.cpp AK+Everywhere: Rename String to DeprecatedString 2022-12-06 08:54:33 +01:00
purge.cpp purge: Port to LibMain 2022-03-22 11:39:20 +01:00
pwd.cpp AK+Everywhere: Rename String to DeprecatedString 2022-12-06 08:54:33 +01:00
readelf.cpp Everywhere: Rename to_{string => deprecated_string}() where applicable 2022-12-06 08:54:33 +01:00
readlink.cpp readlink: Use StringView instead of const char* 2022-03-24 11:57:51 +01:00
realpath.cpp Everywhere: Run clang-format 2022-04-01 21:24:45 +01:00
reboot.cpp AK+Everywhere: Rename String to DeprecatedString 2022-12-06 08:54:33 +01:00
rev.cpp AK+Everywhere: Rename String to DeprecatedString 2022-12-06 08:54:33 +01:00
rm.cpp rm: Port to LibMain 2022-01-25 02:50:10 +00:00
rmdir.cpp AK+Everywhere: Rename String to DeprecatedString 2022-12-06 08:54:33 +01:00
route.cpp Everywhere: Rename to_{string => deprecated_string}() where applicable 2022-12-06 08:54:33 +01:00
run-tests.cpp Everywhere: Rename to_{string => deprecated_string}() where applicable 2022-12-06 08:54:33 +01:00
seq.cpp AK+Everywhere: Rename String to DeprecatedString 2022-12-06 08:54:33 +01:00
shot.cpp LibGfx+Userland: Make PNGWriter::encode() return ErrorOr<ByteBuffer> 2022-12-08 13:01:11 +00:00
shuf.cpp AK+Everywhere: Rename String to DeprecatedString 2022-12-06 08:54:33 +01:00
shutdown.cpp AK+Everywhere: Rename String to DeprecatedString 2022-12-06 08:54:33 +01:00
sleep.cpp Utilities: Use default execpromises parameter to pledge(..) 2022-04-03 17:13:51 -07:00
sort.cpp AK+Everywhere: Rename String to DeprecatedString 2022-12-06 08:54:33 +01:00
sql.cpp LibSQL+SQLServer+sql: Send and parse the correct number of changed rows 2022-12-07 13:09:00 +01:00
stat.cpp Everywhere: Rename to_{string => deprecated_string}() where applicable 2022-12-06 08:54:33 +01:00
strace.cpp Everywhere: Rename to_{string => deprecated_string}() where applicable 2022-12-06 08:54:33 +01:00
strings.cpp Utilities: Add strings 2022-12-04 12:08:48 +00:00
stty.cpp Everywhere: Rename to_{string => deprecated_string}() where applicable 2022-12-06 08:54:33 +01:00
su.cpp LibCore: Propagate errors from LibCore::Account::login() 2022-09-27 21:29:44 +01:00
sync.cpp sync: Port to LibMain 2022-02-01 04:58:24 +00:00
syscall.cpp Everywhere: Rename to_{string => deprecated_string}() where applicable 2022-12-06 08:54:33 +01:00
sysctl.cpp AK+Everywhere: Rename String to DeprecatedString 2022-12-06 08:54:33 +01:00
tac.cpp AK+Everywhere: Rename String to DeprecatedString 2022-12-06 08:54:33 +01:00
tail.cpp tail: Port to Core::Stream, use Core::FileWatcher 2022-11-02 21:29:20 -06:00
tar.cpp Everywhere: Rename to_{string => deprecated_string}() where applicable 2022-12-06 08:54:33 +01:00
tee.cpp Everywhere: Use my fairly new and shiny serenityos.org email :^) 2022-06-30 15:59:42 +01:00
telws.cpp AK+Everywhere: Rename String to DeprecatedString 2022-12-06 08:54:33 +01:00
test-bindtodevice.cpp test-bindtodevice: Port to LibMain 2022-03-29 21:28:29 -07:00
test-fuzz.cpp AK+Everywhere: Rename String to DeprecatedString 2022-12-06 08:54:33 +01:00
test-imap.cpp AK+Everywhere: Rename String to DeprecatedString 2022-12-06 08:54:33 +01:00
test-pthread.cpp Everywhere: Run clang-format 2022-12-03 23:52:23 +00:00
test-unveil.cpp LibCore: Replace the ArgsParser option argument setting with an enum 2022-07-14 00:24:24 +01:00
test.cpp AK+Everywhere: Rename String to DeprecatedString 2022-12-06 08:54:33 +01:00
test_env.cpp Everywhere: Run clang-format 2022-04-01 21:24:45 +01:00
timezone.cpp Everywhere: Update copyrights with my new serenityos.org e-mail :^) 2022-01-31 18:23:22 +00:00
top.cpp AK+Everywhere: Rename String to DeprecatedString 2022-12-06 08:54:33 +01:00
touch.cpp LibCore: Move Core::Stream::File::exists() to Core::File 2022-12-08 12:52:14 +00:00
tr.cpp Everywhere: Rename to_{string => deprecated_string}() where applicable 2022-12-06 08:54:33 +01:00
traceroute.cpp AK+Everywhere: Rename String to DeprecatedString 2022-12-06 08:54:33 +01:00
tree.cpp Everywhere: Rename to_{string => deprecated_string}() where applicable 2022-12-06 08:54:33 +01:00
true.cpp true: Port to LibMain 2022-03-22 11:39:20 +01:00
truncate.cpp AK+Everywhere: Rename String to DeprecatedString 2022-12-06 08:54:33 +01:00
tt.cpp Everywhere: Run clang-format 2022-04-01 21:24:45 +01:00
tty.cpp tty: Port to LibMain 2022-03-29 21:28:29 -07:00
umount.cpp umount: Port to LibMain 2022-01-22 13:31:52 +02:00
uname.cpp Everywhere: Rename to_{string => deprecated_string}() where applicable 2022-12-06 08:54:33 +01:00
uniq.cpp AK+Everywhere: Rename String to DeprecatedString 2022-12-06 08:54:33 +01:00
unveil.cpp AK+Everywhere: Rename String to DeprecatedString 2022-12-06 08:54:33 +01:00
unzip.cpp AK+Everywhere: Rename String to DeprecatedString 2022-12-06 08:54:33 +01:00
update-cpp-test-results.cpp AK+Everywhere: Rename String to DeprecatedString 2022-12-06 08:54:33 +01:00
uptime.cpp Utilities: Use new global variables at /sys/kernel/ directory 2022-10-25 15:33:34 -06:00
useradd.cpp AK+Everywhere: Rename String to DeprecatedString 2022-12-06 08:54:33 +01:00
userdel.cpp AK+Everywhere: Rename String to DeprecatedString 2022-12-06 08:54:33 +01:00
usermod.cpp LibCore: Use StringView instead of char * in Account 2022-09-27 21:29:44 +01:00
utmpupdate.cpp Everywhere: Rename to_{string => deprecated_string}() where applicable 2022-12-06 08:54:33 +01:00
w.cpp Everywhere: Rename to_{string => deprecated_string}() where applicable 2022-12-06 08:54:33 +01:00
wallpaper.cpp AK+Everywhere: Rename String to DeprecatedString 2022-12-06 08:54:33 +01:00
wasm.cpp Everywhere: Rename to_{string => deprecated_string}() where applicable 2022-12-06 08:54:33 +01:00
watch.cpp AK+Everywhere: Rename String to DeprecatedString 2022-12-06 08:54:33 +01:00
wc.cpp AK+Everywhere: Rename String to DeprecatedString 2022-12-06 08:54:33 +01:00
which.cpp Userland: Consolidate most PATH resolving into a single implementation 2022-08-23 19:00:04 +01:00
whoami.cpp whoami: Port to LibMain :^) 2021-11-30 23:34:40 +01:00
wsctl.cpp Userland: Always construct Application with try_create() 2022-04-18 12:57:34 +02:00
xargs.cpp Everywhere: Rename to_{string => deprecated_string}() where applicable 2022-12-06 08:54:33 +01:00
xml.cpp Everywhere: Rename to_{string => deprecated_string}() where applicable 2022-12-06 08:54:33 +01:00
yes.cpp Everywhere: Run clang-format 2022-04-01 21:24:45 +01:00
zip.cpp AK+Everywhere: Rename String to DeprecatedString 2022-12-06 08:54:33 +01:00