Commit Graph

19 Commits

Author SHA1 Message Date
Tim Schumacher
606a3982f3 LibCore: Move Stream-based file into the Core namespace 2023-02-13 00:50:07 +00:00
Tim Schumacher
d43a7eae54 LibCore: Rename File to DeprecatedFile
As usual, this removes many unused includes and moves used includes
further down the chain.
2023-02-13 00:50:07 +00:00
Sam Atkins
ba51e2dd3f Services: Replace uses of JsonObject::get_deprecated()/get_ptr() 2023-01-27 08:07:24 -05:00
Sam Atkins
1dd6b7f5b7 AK+Everywhere: Rename JsonObject::get() to ::get_deprecated()
This is a preparatory step to making `get()` return `ErrorOr`.
2023-01-17 19:52:52 -05:00
Tim Schumacher
ed4c2f2f8e LibCore: Rename Stream::read_all to read_until_eof
This generally seems like a better name, especially if we somehow also
need a better name for "read the entire buffer, but not the entire file"
somewhere down the line.
2022-12-12 14:16:42 +01:00
Linus Groh
57dc179b1f Everywhere: Rename to_{string => deprecated_string}() where applicable
This will make it easier to support both string types at the same time
while we convert code, and tracking down remaining uses.

One big exception is Value::to_string() in LibJS, where the name is
dictated by the ToString AO.
2022-12-06 08:54:33 +01:00
Linus Groh
6e19ab2bbc AK+Everywhere: Rename String to DeprecatedString
We have a new, improved string type coming up in AK (OOM aware, no null
state), and while it's going to use UTF-8, the name UTF8String is a
mouthful - so let's free up the String name by renaming the existing
class.
Making the old one have an annoying name will hopefully also help with
quick adoption :^)
2022-12-06 08:54:33 +01:00
Tim Schumacher
ce2f1b845f Everywhere: Mark dependencies of most targets as PRIVATE
Otherwise, we end up propagating those dependencies into targets that
link against that library, which creates unnecessary link-time
dependencies.

Also included are changes to readd now missing dependencies to tools
that actually need them.
2022-11-01 14:49:09 +00:00
Liav A
35c98a031a Services: Use new global variables at /sys/kernel/ directory 2022-10-25 15:33:34 -06:00
huttongrabiel
4806567f05 NetworkServer: Use Core::Stream instead of Core::File
As per the FIXME.
2022-08-23 13:37:21 +01:00
Maciej
976562b817 NetworkServer: Use sv suffixes to avoid strlen at runtime 2022-07-14 23:26:47 +02:00
Maciej
b5708a084b NetworkServer: Disable interface if Enabled = false
We now remove default route and set IP address to 0.0.0.0 (Kernel
interprets this as "link down") for all disabled interfaces, so that
a reboot is no longer needed.
2022-07-14 23:26:47 +02:00
Maciej
211ced3b65 NetworkServer: Kill DHCPServer as the first thing done
The DHCPServer running while we setup interfaces might manage to setup
its own config before we kill it.
2022-07-14 23:26:47 +02:00
sin-ack
3f3f45580a Everywhere: Add sv suffix to strings relying on StringView(char const*)
Each of these strings would previously rely on StringView's char const*
constructor overload, which would call __builtin_strlen on the string.
Since we now have operator ""sv, we can replace these with much simpler
versions. This opens the door to being able to remove
StringView(char const*).

No functional changes.
2022-07-12 23:11:35 +02:00
Maciej
df7b7cbfa4 NetworkServer: Kill running DHCPServer before starting our own
We cannot run two DHCPServers at once, let's just kill the one that was
started previously.
2022-07-09 09:22:25 +01:00
Maciej
8526c3f680 NetworkServer: Clear default gateway route entry before adding 2022-07-09 09:22:25 +01:00
Maciej
65307cf5cc NetworkServer: Enable DHCP on interfaces that are not listed in config 2022-07-04 13:20:24 +03:00
Maciej
1ffba0b8b4 NetworkServer: Support setting default gateway
This commit adds an IPv4Gateway to Network.ini. If that option is set to
value other than 0.0.0.0, the NetworkServer adds a default route (e.g.
with address 0.0.0.0/0) with the specified destination.
2022-05-28 23:33:46 +01:00
Maciej
ddd4547e13 NetworkServer: Add a new NetworkServer service
This service is responsible for loading network configuration from a
/etc/Network.ini config file. It sets up static IP address + mask or
starts DHCPClient depending on configuration.
2022-05-26 21:47:27 +01:00