Commit Graph

64640 Commits

Author SHA1 Message Date
Máximo Castañeda
770c98e56f MediaPlayer: fix subtitles
- Setting word wrapping and resizing the BTextView to the video size
  before adding the text moves the subtitles to where they are supposed
  to be, and breaks long lines that would be cut off.
- Show last subtitle entry: _IndexFor returns the index at which to
  insert a new subtitle for some start time, so when getting an existing
  one, we always need the previous index. Before the change we would do
  that after checking the time of the subtitle at the returned index,
  which for the times of the last one would be outside the list.
- Improve charset detection by using the whole file. Just the first line
  of subtitle text may be too short to be useful, and to get there we
  should have decoded the file first. The refactor also fixes not getting
  the last entry from the file.
- While not subtitle related, fix typo in aspect ratio menu shortcuts.

Fixes #18151

Change-Id: I83fae735d31bce4616da9128a46be15763c30591
Reviewed-on: https://review.haiku-os.org/c/haiku/+/7833
Reviewed-by: waddlesplash <waddlesplash@gmail.com>
Haiku-Format: Haiku-format Bot <no-reply+haikuformatbot@haiku-os.org>
Tested-by: Commit checker robot <no-reply+buildbot@haiku-os.org>
(cherry picked from commit a5df3d5221)
Reviewed-on: https://review.haiku-os.org/c/haiku/+/7856
Reviewed-by: Adrien Destugues <pulkomandy@pulkomandy.tk>
2024-07-30 09:28:56 +00:00
Máximo Castañeda
94777a3d5b app_server: update Symbols2 font name
It's changed in the version included in current noto package.

Fixes #18815

Change-Id: I6e2db902dff0f72f1a13ef5eafb2b9963e466e4a
Reviewed-on: https://review.haiku-os.org/c/haiku/+/7425
Reviewed-by: Máximo Castañeda <antiswen@yahoo.es>
(cherry picked from commit 118eb80985)
Reviewed-on: https://review.haiku-os.org/c/haiku/+/7436
Reviewed-by: Adrien Destugues <pulkomandy@pulkomandy.tk>
2024-02-27 20:17:19 +00:00
X512
ed61b79174 vfs/preallocate: fix file descriptor leak
Fixes #18724.

Change-Id: I1a17a36106d13853888342a397ecd03087b1fdcf
Reviewed-on: https://review.haiku-os.org/c/haiku/+/7299
Reviewed-by: waddlesplash <waddlesplash@gmail.com>
(cherry picked from commit 3433ec7334)
Reviewed-on: https://review.haiku-os.org/c/haiku/+/7218
2024-01-08 18:41:46 +00:00
Freaxed
2ad546a6bc BColumnListView: Resolve column resizing drawing glitch (wider than 600px)
* use of a shared bitmap buffer in OutlineView and TitleView
* dynamically increase of the bitmap buffer after adding a column or a row

Fixes #14888

Change-Id: I4feddf636fb1446c29e60353b8f70fc084833731
Reviewed-on: https://review.haiku-os.org/c/haiku/+/7176
Reviewed-by: John Scipione <jscipione@gmail.com>
Reviewed-by: Adrien Destugues <pulkomandy@pulkomandy.tk>
Reviewed-by: Stefano Ceccherini <stefano.ceccherini@gmail.com>
Tested-by: Commit checker robot <no-reply+buildbot@haiku-os.org>
(cherry picked from commit 94b4024f22)
Reviewed-on: https://review.haiku-os.org/c/haiku/+/7216
Reviewed-by: Jérôme Duval <jerome.duval@gmail.com>
2023-12-24 13:21:41 +00:00
David Karoly
fab984f606 Debugger: implement DWARFv5 line-info handling
* add new field for .debug_line_str section
* implement reading string and int values tagged with DW_FORM_*
* skip new fields addressSize, segmentSelectorSize in line info header
* parse directories and file names according to new syntax
* enable line-info parsing up to version 5

Change-Id: I1dd7e0d834c73f6d72b7115c7ded9f868be84a3d
Reviewed-on: https://review.haiku-os.org/c/haiku/+/6978
Reviewed-by: Rene Gollent <rene@gollent.com>
Tested-by: Commit checker robot <no-reply+buildbot@haiku-os.org>
Reviewed-on: https://review.haiku-os.org/c/haiku/+/7049
Reviewed-by: Adrien Destugues <pulkomandy@pulkomandy.tk>
Reviewed-by: Jérôme Duval <jerome.duval@gmail.com>
2023-10-19 16:27:43 +00:00
David Karoly
05e56efe69 Debugger: add DWARFv5 constants to Dwarf.h
Change-Id: I81d3e3cc6d896ca90e8c10f01783cc294b91886f
Reviewed-on: https://review.haiku-os.org/c/haiku/+/6903
Tested-by: Commit checker robot <no-reply+buildbot@haiku-os.org>
Reviewed-by: Adrien Destugues <pulkomandy@pulkomandy.tk>
(cherry picked from commit 05f767f88d)
Reviewed-on: https://review.haiku-os.org/c/haiku/+/7018
Reviewed-by: Jérôme Duval <jerome.duval@gmail.com>
2023-10-17 15:42:53 +00:00
David Karoly
c1ca5e5feb Debugger: implement parsing for v4 line-info
Differences between DWARF v3/v4 for line-info:
- added new field maxOpsPerInstruction
  this new field will typically have the value of 1
  unless VLIW architecture is being used
  (which is not the case for Haiku)
- state machine contains a new field op_index
  it has any relevance only when maxOpsPerInstruction > 1
  i.e. on VLIW architectures
- added new operation DW_LNE_set_discriminator
  this is already implemented in LineNumberProgram.cpp

This implementation just reads maxOpsPerInstruction and
checks that it is set to 1, which is what we expect on
all architectures currently supported by Haiku.

Change-Id: I14755d615a0e2b3a5177928c4d8f9014940a5fcf
Reviewed-on: https://review.haiku-os.org/c/haiku/+/6876
Reviewed-by: Rene Gollent <rene@gollent.com>
(cherry picked from commit 3f2464f759)
Reviewed-on: https://review.haiku-os.org/c/haiku/+/7017
Reviewed-by: waddlesplash <waddlesplash@gmail.com>
2023-10-07 19:41:07 +00:00
KENZ
dca65c878f Debugger: just skip .debug_frame/.eh_frame section contains a 0-length CIE
Some executables (or shared objects) may have .debug_frame or
.eh_frame section which contains the CIE(/FDE) length is 0.
The DWARF spec doesn't describe this case explicitly, but doesn't
prohibit it.
LSB says to treat this a terminator of the CIE.

https://refspecs.linuxbase.org/LSB_5.0.0/LSB-Core-generic/LSB-Core-generic/ehframechpt.html

Previous code failed to load the entire debug info of the
executable.

New code just skip these section (don't read anymore) after the
Debugger (kit) encounter a 0-length CIE.

Fixes #18438.

Change-Id: I382d0ec409d40570b5bccd384d38fa3c29ae2e7f
Reviewed-on: https://review.haiku-os.org/c/haiku/+/6538
Reviewed-by: Rene Gollent <rene@gollent.com>
Tested-by: Commit checker robot <no-reply+buildbot@haiku-os.org>
(cherry picked from commit f0e9ed4488)
Reviewed-on: https://review.haiku-os.org/c/haiku/+/7016
Reviewed-by: Adrien Destugues <pulkomandy@pulkomandy.tk>
2023-10-07 19:26:04 +00:00
Augustin Cavalier
5c6cea9dd7 Debugger: Move line-info version check up and print a warning.
This way it will be clear why there is no line-info.

Change-Id: I2e5d0e1f90edabfde6c3f637320a82e7f988fe20
Reviewed-on: https://review.haiku-os.org/c/haiku/+/6990
Reviewed-by: waddlesplash <waddlesplash@gmail.com>
2023-10-07 14:57:05 +00:00
Augustin Cavalier
d252971b89 Debugger: Downgrade a warning to a TRACE.
We don't need to know all the objects which have no
debug information; this just spams the console.

Change-Id: Ib0bfbf87f6d7076504ad70ba96ce646bf8c7a6de
Reviewed-on: https://review.haiku-os.org/c/haiku/+/6989
Reviewed-by: waddlesplash <waddlesplash@gmail.com>
2023-10-07 14:56:56 +00:00
Alexander von Gluck IV
6b133d45d5 headers/os: Bump max gcc to 13.x
* riscv64 builds fine
* x86_64 builds and boots fine

Change-Id: I98b72a9d57b1a6ea0fae5c113a4c24b32fd68a52
Reviewed-on: https://review.haiku-os.org/c/haiku/+/6425
Reviewed-by: Adrien Destugues <pulkomandy@pulkomandy.tk>
(cherry picked from commit d9642c25bb)
Reviewed-on: https://review.haiku-os.org/c/haiku/+/6676
2023-07-01 23:31:39 +00:00
Augustin Cavalier
b2dcaeb585 kernel/fd: Add missing NULL checks in user_io routines.
I am not sure how this path could be hit besides having
O_APPEND set on a socket, which appears to be possible,
though I don't know what purpose that would serve.

Tested by adding these two lines between the sleep() and close()
in the in-tree tcp_connection_test:

fcntl(fd, F_SETFL, O_APPEND);
write(fd, "Hello", 5);

Before this commit, the above lines cause a KDL.

May fix #18133, but I don't presently have access to the
reproduction setup described in that ticket.
2023-05-22 22:38:59 +00:00
Jessica Hamilton
8ac690a419 duplocale: fix missing locale magic when creating a new locale.
Fixes #18345.

Change-Id: Ibedfa973b371b65a502dc655eae65f4ed0833144
Reviewed-on: https://review.haiku-os.org/c/haiku/+/6368
Reviewed-by: John Scipione <jscipione@gmail.com>
Reviewed-by: Adrien Destugues <pulkomandy@pulkomandy.tk>
2023-05-20 15:11:52 +00:00
Máximo Castañeda
3a554d1d54 FlatControlLook: fix clipping
Remove ConstrainClippingRegion calls as they do not take into account
view transformations.
Clip drawing to the drawing rect, not the updated area.

Part of #12890

Change-Id: Icbc07f5431cf8ee826f28e6d5683135d1171d75a
(cherry picked from commit cd6e756df5)
Reviewed-on: https://review.haiku-os.org/c/haiku/+/6408
Reviewed-by: waddlesplash <waddlesplash@gmail.com>
2023-05-11 15:48:24 +00:00
John Scipione
83297df03e BeControlLook: fix clipping rect, part of #12890
Change-Id: Ib3c29dd1ffba1f0456a5043b62d943123335e966
Reviewed-on: https://review.haiku-os.org/c/haiku/+/6366
Tested-by: Commit checker robot <no-reply+buildbot@haiku-os.org>
Reviewed-by: waddlesplash <waddlesplash@gmail.com>
(cherry picked from commit c7cd1bae68)
Reviewed-on: https://review.haiku-os.org/c/haiku/+/6341
2023-05-11 15:48:24 +00:00
Máximo Castañeda
44cb8f3601 ControlLook: fix clipping
Remove ConstrainClippingRegion calls as they do not take into
account view transformations.
Clip drawing to the drawing rect, not the updated area.

Fixes #12890

Change-Id: Ie76cb83e0af03213008da78407de25261daea5df
Reviewed-on: https://review.haiku-os.org/c/haiku/+/4457
Tested-by: Commit checker robot <no-reply+buildbot@haiku-os.org>
Reviewed-by: Adrien Destugues <pulkomandy@pulkomandy.tk>
Reviewed-by: waddlesplash <waddlesplash@gmail.com>
(cherry picked from commit e6a598a2f4)
Reviewed-on: https://review.haiku-os.org/c/haiku/+/6340
2023-05-11 15:48:24 +00:00
Augustin Cavalier
ef91a0020c kernel/team: Fix race condition in team loading wait.
The condition variable that the load_image'ing thread is waiting on
is also owned by that same thread, so as soon as it wakes up, it
will soon return, thus destroying it. Under high load or other unlucky
scheduling conditions, it seems this could occur before the other thread
had even returned from the condition variable's NotifyAll.

Since team->loading_info is protected by the team lock, simply
acquire the team lock once more after being awoken and returning,
to synchronize and prevent this race.

Should fix #18352.

Change-Id: Ibabda436ffd07149c2012e6c797ff0c0933aebe3
Reviewed-on: https://review.haiku-os.org/c/haiku/+/6317
Reviewed-by: Adrien Destugues <pulkomandy@pulkomandy.tk>
2023-05-01 21:50:38 +00:00
Trung Nguyen
4ae9b0a03e libroot: Fix bad pointer access in __init_stack_protector
The address of the variable should be taken instead of the
variable itself being casted to `void*`.

This fixes a rare segfault bug when any Haiku binary runs in
a `chroot`ed environment without a `/dev` mount.

Change-Id: I2fdacac62fadbcce8006bbf0a5350f6ec95133ae
Reviewed-on: https://review.haiku-os.org/c/haiku/+/6377
Tested-by: Commit checker robot <no-reply+buildbot@haiku-os.org>
Reviewed-by: Jérôme Duval <jerome.duval@gmail.com>
(cherry picked from commit 7bfc9c6fc7)
Reviewed-on: https://review.haiku-os.org/c/haiku/+/6338
Reviewed-by: Adrien Destugues <pulkomandy@pulkomandy.tk>
2023-05-01 21:50:33 +00:00
Augustin Cavalier
e0bf577acd libroot: Fix initialization of LocaleNumericDataBridge.
We need to store the isGlobal value, so that the destructor
can take care of unsetting the glibc locale properly.

It seems this has been broken since d338200e2b.

Fixes #18344 and probably #18336.

Change-Id: Idb9b33cd1416969e01b73012de059ff051b76e74
Reviewed-on: https://review.haiku-os.org/c/haiku/+/6373
Reviewed-by: Fredrik Holmqvist <fredrik.holmqvist@gmail.com>
2023-04-27 06:59:21 +00:00
Jérôme Duval
ad5f3ccd7c tcp: avoid overflow of the advertised window with window scaling enabled
tcp_segment_header.advertised_window is 16 bits.

Previously, instead of using the maximum window, zero would be sent, thus
the partner wouldn't send anything.

fix #18337

Change-Id: Ibff98ee58b84bdf52527a7821648a5faf20c5589
Reviewed-on: https://review.haiku-os.org/c/haiku/+/6359
Tested-by: Commit checker robot <no-reply+buildbot@haiku-os.org>
Reviewed-by: Adrien Destugues <pulkomandy@pulkomandy.tk>
(cherry picked from commit 7c58a5a3fb)
Reviewed-on: https://review.haiku-os.org/c/haiku/+/6339
Reviewed-by: waddlesplash <waddlesplash@gmail.com>
2023-04-16 18:54:22 +00:00
John Scipione
8a68624821 Deskbar: Limit app bar width by BarMenuBar width
... in horizontal mode instead of (mis)calculating it.

Fixes #18299

Change-Id: I33bddd5f985677f7730f0025291fdfae90f4cb76
Reviewed-on: https://review.haiku-os.org/c/haiku/+/6214
Tested-by: Commit checker robot <no-reply+buildbot@haiku-os.org>
Tested-by: Automation <automation@haiku-os.org>
Reviewed-by: waddlesplash <waddlesplash@gmail.com>
(cherry picked from commit 7ee7b33be6)
Reviewed-on: https://review.haiku-os.org/c/haiku/+/6337
Reviewed-by: John Scipione <jscipione@gmail.com>
2023-04-10 17:32:45 +00:00
Augustin Cavalier
a992c1aa42 threads.h: Fix value of ONCE_FLAG_INIT.
Fixes #18348.

Change-Id: I41cbfc4dce6ee88d7e6163ee7416d1c533004788
Reviewed-on: https://review.haiku-os.org/c/haiku/+/6322
Reviewed-by: Alex von Gluck IV <kallisti5@unixzen.com>
2023-04-10 17:06:34 +00:00
Emmanuel Gil Peyrot
7de2572f79 mime_db: Broaden AVIF filetype guess
The current version expects the first box to be exactly 32 bytes, but some
files found in the wild only have 28 bytes, so we now ignore the first four
bytes and it works.

Change-Id: I4c304bd6385bffd15f4adbb99cbf464f9767f7bf
Reviewed-on: https://review.haiku-os.org/c/haiku/+/6302
Tested-by: Automation <automation@haiku-os.org>
Reviewed-by: nephele <nep@packageloss.eu>
Reviewed-by: waddlesplash <waddlesplash@gmail.com>
Reviewed-on: https://review.haiku-os.org/c/haiku/+/6320
Reviewed-by: Alex von Gluck IV <kallisti5@unixzen.com>
2023-04-09 21:17:43 +00:00
PulkoMandy
af6a81f370 BitmapStream: fix grayscale AVIF decoding
BitmapStream creates a BBitmap without specifying a bytes per row, but
then check the bytes per row matches the header. It is better to ask
BBitmap for the desired bytes per row to avoid any difference in
padding.

Change-Id: Ie1facfd423ad888a14757a0fffc9e8cdf72ef832
Reviewed-on: https://review.haiku-os.org/c/haiku/+/6301
Tested-by: Automation <automation@haiku-os.org>
Reviewed-by: waddlesplash <waddlesplash@gmail.com>
Reviewed-on: https://review.haiku-os.org/c/haiku/+/6319
Reviewed-by: Alex von Gluck IV <kallisti5@unixzen.com>
2023-04-09 21:17:43 +00:00
Augustin Cavalier
4b464b3ccc getlogin_r: Make actually reentrant and fix error return value.
Fixes #18349.

Change-Id: I6029344a02cc14dedcf2e93ee0b7dab23ebc7275
Reviewed-on: https://review.haiku-os.org/c/haiku/+/6318
Reviewed-by: Alex von Gluck IV <kallisti5@unixzen.com>
2023-04-09 21:17:43 +00:00
Augustin Cavalier
bd25cdf88f uchar.h: Add missing include of stdint.h.
Fixes #17040.

Change-Id: Ic9b47fa237a7f34e72c26f19efcfb7aea30c7161
Reviewed-on: https://review.haiku-os.org/c/haiku/+/6316
Reviewed-by: Alex von Gluck IV <kallisti5@unixzen.com>
2023-04-09 21:16:23 +00:00
Jérôme Duval
943dda487c libroot/glibc: apply upstream fix for printf_fphex: Fix up long double fphex.
a53b7a4e4b
fix #18353
Change-Id: I7d8cb2be2b1e1751a183dcc712abc2de55285d30
Reviewed-on: https://review.haiku-os.org/c/haiku/+/6315
Reviewed-by: Alex von Gluck IV <kallisti5@unixzen.com>
2023-04-09 21:16:23 +00:00
PulkoMandy
6c9df5cb58 BControl: fix big-endian bitmap handling for control icons
The code is endian-dependant because the alpha channel is not at the
same place. This resulted in transparent white in icons being converted
to partially transparent yellow when attempting to darken the icons, for
example.

Change-Id: I57916139ba37b8d7ae0f9e9ba9e74c1d496d7b05
Reviewed-on: https://review.haiku-os.org/c/haiku/+/6077
Tested-by: Automation <automation@haiku-os.org>
Reviewed-by: waddlesplash <waddlesplash@gmail.com>
(cherry picked from commit 3cc1da2b77)
Reviewed-on: https://review.haiku-os.org/c/haiku/+/6096
2023-02-20 07:55:44 +00:00
Dale Cieslak
233d22fe6b BFont: Stub API for file and memory font loading
* Added APIs for file and memory font loading that return B_NOT_SUPPORTED
when called, as requested in #16101 for forwards-compatibility with
r1beta5.
* changed uint32 size and offset arguments to size_t

Change-Id: I3dc39c233c00c05a34439e7d02cf2a4e41b97e63
Reviewed-on: https://review.haiku-os.org/c/haiku/+/6004
Reviewed-by: nephele <nep@packageloss.eu>
Reviewed-by: Adrien Destugues <pulkomandy@pulkomandy.tk>
2023-02-06 17:54:42 +00:00
Alexander von Gluck IV
6c4363388a rootfs: Introduce permissions to virtual rootfs filesystem
Change-Id: I12b1e611cb88421005f34e279b02d20199b3fa52
Reviewed-on: https://review.haiku-os.org/c/haiku/+/5964
Reviewed-by: Alex von Gluck IV <kallisti5@unixzen.com>
Reviewed-by: waddlesplash <waddlesplash@gmail.com>
Tested-by: Commit checker robot <no-reply+buildbot@haiku-os.org>
(cherry picked from commit 1f846c9cc5)
Reviewed-on: https://review.haiku-os.org/c/haiku/+/5928
Reviewed-by: Adrien Destugues <pulkomandy@pulkomandy.tk>
2023-01-26 00:12:33 +00:00
PulkoMandy
0aa990ad40 ffmpeg: fix incorrect error check
The function returns a positive nonzero value when it works.

Change-Id: Ib5852ec1d71e44b67309f3b955b888708f2ba1cf
Reviewed-on: https://review.haiku-os.org/c/haiku/+/6020
Reviewed-by: waddlesplash <waddlesplash@gmail.com>
2023-01-26 00:05:43 +00:00
PulkoMandy
49cb8b31ca ffmpeg: fix missing initialization of AVFrame
ffmpeg API reference does not allow to allocate AVFrame on the stack,
and especially not without initializing anything in the frame. Calling
av_frame_unref then attempts to free some non-existing data, and
crashes.

The code for video was already using a correctly allocated frame, which
we can reuse here.

Fixes #17415

Probably fixes #16831

Change-Id: I91054dc41f0a91be9c585ec927e77bfc874a37ea
Reviewed-on: https://review.haiku-os.org/c/haiku/+/6019
Reviewed-by: waddlesplash <waddlesplash@gmail.com>
2023-01-26 00:05:43 +00:00
Alexander von Gluck IV
16abf33674 system/kernel: Fix virtual / permissions
* Solves some insecure permission errors with
  sshd subprocesses.
* More secure I guess not letting "anyone" write to /

Change-Id: I1bb31ff0142585639369f7b3d15cf9a2d5755598
Reviewed-on: https://review.haiku-os.org/c/haiku/+/5962
Tested-by: Commit checker robot <no-reply+buildbot@haiku-os.org>
Reviewed-by: waddlesplash <waddlesplash@gmail.com>
Reviewed-by: Alex von Gluck IV <kallisti5@unixzen.com>
(cherry picked from commit 151482229c)
Reviewed-on: https://review.haiku-os.org/c/haiku/+/5927
2022-12-27 16:32:32 +00:00
PulkoMandy
771538f0ba mime_db: add a sniffing rule for css
Just like the one for HTML, we have to do a bit of guessing since there
is no easy structure. We can extend it with more keyowrds or remove some
if we find some problems with other files.

Tested so far with the Be Book and Haiku user guide CSS files.

Fixes #18144.

Change-Id: If04fba18846d17ba0eb28dd0bd12787f1fe32028
Reviewed-on: https://review.haiku-os.org/c/haiku/+/5948
Tested-by: Commit checker robot <no-reply+buildbot@haiku-os.org>
Reviewed-by: Máximo Castañeda <antiswen@yahoo.es>
Reviewed-by: Adrien Destugues <pulkomandy@pulkomandy.tk>
Reviewed-by: nephele <nep@packageloss.eu>
(cherry picked from commit 4562b1727c)
Reviewed-on: https://review.haiku-os.org/c/haiku/+/5926
Reviewed-by: waddlesplash <waddlesplash@gmail.com>
2022-12-23 01:55:25 +00:00
PulkoMandy
34b77b942e ffmpeg: leak when re-allocating ffmpeg context
The _Setup method can be called several times if the parameters are
changed (for example when calling SetQuality). But it always allocated a
new context without freeinthe previous one, resulting in a leak.

Part of #9458, it fixes the largest leak there (10K bytes for each loop
of the provided test) but there are other leaks left as well, some of
which apparently need an update to a newer ffmpeg version removing some
deprecated fields.

Change-Id: Iad119dbda9cff1ce023b602a1978b100a1263f7d
Reviewed-on: https://review.haiku-os.org/c/haiku/+/5953
Reviewed-by: waddlesplash <waddlesplash@gmail.com>
(cherry picked from commit beff8fa729)
Reviewed-on: https://review.haiku-os.org/c/haiku/+/5925
2022-12-22 15:56:47 +00:00
Autocomitter
400b0f808c Update translations from Pootle 2022-12-17 08:26:02 +00:00
Autocomitter
f421200d00 Update translations from Pootle 2022-12-17 08:26:02 +00:00
Autocomitter
da6b2414cb Update translations from Pootle 2022-12-17 08:26:02 +00:00
Augustin Cavalier
427288d61d HaikuPorts: Synchronize.
(cherry picked from commit 3d6c6ac7f5)

Change-Id: Ib14fc753ab1f45df0968397ddadd5660e725fe35
Reviewed-on: https://review.haiku-os.org/c/haiku/+/5924
Reviewed-by: waddlesplash <waddlesplash@gmail.com>
2022-12-16 21:29:47 +00:00
Augustin Cavalier
513b1cb88b HaikuPorts/x86_gcc2: Synchronize.
(cherry picked from commit 9bcf5c9ce3)

Change-Id: I7b119844e49f44dcb3cb0f49a8c43e15b8f7f21b
Reviewed-on: https://review.haiku-os.org/c/haiku/+/5923
Reviewed-by: waddlesplash <waddlesplash@gmail.com>
2022-12-15 05:33:32 +00:00
Augustin Cavalier
94650b9d7a HaikuPorts/x86_64: Synchronize.
(cherry picked from commit 5f50bcdfe2)

Change-Id: Ic9218620e86fe86722df7622698bbc4f010404c1
Reviewed-on: https://review.haiku-os.org/c/haiku/+/5922
Reviewed-by: waddlesplash <waddlesplash@gmail.com>
2022-12-15 05:04:33 +00:00
Jérôme Duval
7fada5d082 efi/x86_64: skip reserved memory blocks when finding out the memory top
fix #16712

Change-Id: Ib2ae08bc47008098a6b0c231a759d5e91f88fd33
Reviewed-on: https://review.haiku-os.org/c/haiku/+/5912
Tested-by: Commit checker robot <no-reply+buildbot@haiku-os.org>
Reviewed-by: waddlesplash <waddlesplash@gmail.com>
(cherry picked from commit 7fb137c2b2)
Reviewed-on: https://review.haiku-os.org/c/haiku/+/5921
2022-12-15 04:14:05 +00:00
Oscar Lesta
f06e09cf13 ramfs: add B_FS_IS_REMOVABLE as a workaround for #18137
This work-arounds the issue of the VirtualMemory preflet showing
RAM FS volumes as valid storage options for the swap file.

Removing B_FS_IS_PERSISTENT didn't work as I originally expected,
causing problems when attempting to write/delete entries on RAMFS
mounts after that.

Kudos to waddlesplash for the B_FS_IS_REMOVABLE alternative.

Change-Id: Id5ba1fa192b63b944cf59413a7f580ebb608e50d
Reviewed-on: https://review.haiku-os.org/c/haiku/+/5911
Reviewed-by: waddlesplash <waddlesplash@gmail.com>
(cherry picked from commit 1cae9edcc7)
Reviewed-on: https://review.haiku-os.org/c/haiku/+/5920
2022-12-14 18:37:15 +00:00
Jérôme Duval
6bf3b1cfea usb_raw: abort transfers cleanly on kill, fix use-after-free
* aborted transfers will release the notify semaphore when the cancel is notified.
* the allocated buffer would be freed on return, while the usb stack eventually copied
data in the buffer in our back, leading to KDL crashes, because the freed buffer would
be right reallocated for some kernel team structures.
* regression introduced by hrev55806, the transfers didn't need to be cancelled before.

Change-Id: Ifb6e941f71d05c37c36f878059c33883bb72a67c
Reviewed-on: https://review.haiku-os.org/c/haiku/+/5905
Reviewed-by: Adrien Destugues <pulkomandy@pulkomandy.tk>
Reviewed-by: waddlesplash <waddlesplash@gmail.com>
Tested-by: Commit checker robot <no-reply+buildbot@haiku-os.org>
(cherry picked from commit 76ddb69a3a)
Reviewed-on: https://review.haiku-os.org/c/haiku/+/5919
2022-12-14 04:53:30 +00:00
Adrien Destugues
dbae8e42da hoard2: make block header size a multiple of 16 bytes
On 32bit x86 gcc11, allocations should be aligned to 16 bytes, but the
block header (which is stored before the allocations) contains two
pointers, which on a 32bit system results in 8 bytes. Add some padding
to make this header 16 bytes, guaranteeing that the data area is
actually aligned.

Fixes #18111.

Change-Id: Id23f8c0272d75090710f872b728852cd0fcb19ac
Reviewed-on: https://review.haiku-os.org/c/haiku/+/5916
Reviewed-by: Alex von Gluck IV <kallisti5@unixzen.com>
Reviewed-by: waddlesplash <waddlesplash@gmail.com>
2022-12-13 01:55:17 +00:00
Oscar Lesta
0841580ae7 env vars: move XDG Base Dirs variable exports to SetupEnvironment
This makes sure that apps get access to these variables regardless if
they are started from a shell or from GUI (double-click from Tracker,
desklink, etc).

Fixes #18130.

Change-Id: I82e2884e460fad7d6ec16e7b624c5cd2fcf807df
Reviewed-on: https://review.haiku-os.org/c/haiku/+/5897
Tested-by: Commit checker robot <no-reply+buildbot@haiku-os.org>
Reviewed-by: Adrien Destugues <pulkomandy@pulkomandy.tk>
(cherry picked from commit 3af8011358)
Reviewed-on: https://review.haiku-os.org/c/haiku/+/5918
Reviewed-by: waddlesplash <waddlesplash@gmail.com>
2022-12-13 01:52:14 +00:00
X512
950b6b08e7 debug_server: improve stack trace
Change-Id: I94fc9e9e547f0191484cad8e7dc6e8b233b981db
Reviewed-on: https://review.haiku-os.org/c/haiku/+/4299
Reviewed-by: David Karoly <karolyd577@gmail.com>
Reviewed-by: Adrien Destugues <pulkomandy@pulkomandy.tk>
Tested-by: Commit checker robot <no-reply+buildbot@haiku-os.org>
(cherry picked from commit 36fa4b7e7d)
Reviewed-on: https://review.haiku-os.org/c/haiku/+/5917
Reviewed-by: Alex von Gluck IV <kallisti5@unixzen.com>
Reviewed-by: waddlesplash <waddlesplash@gmail.com>
2022-12-13 01:47:58 +00:00
Humdinger
cba5ecbbb4 Thumbnail: fix off-by-one of Height/Width attribute
Fixes #18128

Change-Id: I3abe72552657517acece101a1653b2f013b4f23f
Reviewed-on: https://review.haiku-os.org/c/haiku/+/5881
Tested-by: Commit checker robot <no-reply+buildbot@haiku-os.org>
Reviewed-by: waddlesplash <waddlesplash@gmail.com>
(cherry picked from commit d3811d0036)
Reviewed-on: https://review.haiku-os.org/c/haiku/+/5855
2022-12-08 20:39:58 +00:00
xoblite
6bfa69ea26 Updated the PCI and USB ID lists to the latest versions.
From their respective GitHub repositories:
https://raw.githubusercontent.com/usbids/usbids/master/usb.ids (version 2022.05.20)
https://raw.githubusercontent.com/pciutils/pciids/master/pci.ids (version 2022.12.04)
Change-Id: I9348da6c4dca920e85ea607e8e6c4cf5c2cc41b3
Reviewed-on: https://review.haiku-os.org/c/haiku/+/5874
Reviewed-by: waddlesplash <waddlesplash@gmail.com>
(cherry picked from commit 6dd06f66d0)
Reviewed-on: https://review.haiku-os.org/c/haiku/+/5854
2022-12-07 23:17:37 +00:00
Augustin Cavalier
59e09f7beb libroot: Fix open flags in shm_open.
We need O_CLOEXEC here, not FD_CLOEXEC (which is equal to 0x1, which
in openflags is O_WRONLY and thus leads to the conflicts caught by
the previous commit.)

Fixes haikuports/haikuports#7524.
2022-12-07 17:57:40 -05:00