Commit Graph

23302 Commits

Author SHA1 Message Date
Oliver Ruiz Dorantes
a774d59ff0 Implement handling of the scan mode event reply
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24426 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-03-17 22:41:47 +00:00
Ingo Weinhold
1b32947d3f * Aligned the semantics of the read_symlink() FS module hook with the
readlink() function. It is no longer required to null-terminate the
  string, shall not fail, if the buffer is too small, and shall return
  the length of the string actually written into the buffer.
* Adjusted rootfs, devfs, and bfs accordingly. Also adjusted their
  read_stat() hooks to return the correct symlink length in st_size.
* Our readlink() does now comply to the standard (and BeOS).
  Additionally if the buffer is big enough it is nice to non-conforming
  apps and null-terminates it.
* BSymLink::ReadLink() explicitly null-terminates the string now.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24425 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-03-17 21:37:40 +00:00
Jérôme Duval
4f893e39ab algorithm to find best suited mtrr values to match a memory region. tested ok with 3071MB.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24424 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-03-17 19:50:46 +00:00
Axel Dörfler
e30b6f2693 * There can now be one default route per interface, not just one
default route in the whole stack. The default routes are ordered by
  link speed, so faster interfaces are preferred.
* find_route() by net_route now also checks for the equality of the 
  RTF_DEFAULT flag
* find_route() by address now ignores routes that point to interfaces
  that have no link; if you have more than one configured interface in
  your system, the one with a link is now always chosen.
* get_route_internal() now recognizes AF_LINK addresses, and allows
  one to specify a route by interface this way.
* Implemented update_route_info().
* Minor cleanup, moved copy_address(), and fill_route_entry() into the
  private part of the file.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24423 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-03-17 17:31:51 +00:00
Stephan Aßmus
f306ef434f * Fix build of app_server test environment by implementing atomic_get(),
maybe this should be the assembler version we use for x86, but is probably
  fine for the purpose of the test environment (only BString uses this)
* Fix semantics of DrawingEngine::CopyToFront() which I recently introduced,
  for the fake accelerant of the test environment, we do need to call
  Invalidate(), not CopyBackToFront() directly.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24422 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-03-17 14:28:09 +00:00
Axel Dörfler
0cbc783bc0 * _user_uninitialize_partition() never marked the partition unbusy
again. This fixes bug #1928.
* Added license header.
* Minor cleanup.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24421 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-03-17 13:11:35 +00:00
Axel Dörfler
6011cc673f * Implemented SetContentName(), and SetContentParameters().
* Added license.
* Minor cleanup.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24420 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-03-17 13:07:57 +00:00
Axel Dörfler
e0b38d8aab * Initialize() should also cause initializing the partition which would
only happen if BPartition::SetContentType() set it (which set it 
  only if the original type differed).
* This fixes a part of bug #1928, but of course, it still won't work
  (now the partition reports to be busy).


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24419 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-03-17 12:53:17 +00:00
Rene Gollent
36ac322c47 Fix a case in BShelf where it wouldn't return the error correctly if the replicant was rejected by the shelf. This
would cause various incorrect behavior, best observed in the form of Deskbar crashing if you tried to drag and drop 
a large replicant (i.e. Workspaces) onto it.



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24418 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-03-17 01:20:49 +00:00
Ingo Weinhold
18a83f09cf Root is allowed to cd into any directory, regardless of the directory
permissions.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24417 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-03-16 23:45:10 +00:00
Oliver Ruiz Dorantes
631aa54864 Add scan mode and authentication commands
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24416 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-03-16 22:40:16 +00:00
Bruno G. Albuquerque
c975a408dc - Changed default address for failed DHCP requests from 192.168.0.x to
169.254.0.x, as this is the IANA reserved address for default
  configuration.



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24415 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-03-16 22:24:18 +00:00
Bruno G. Albuquerque
5d27657bfd - Fix building with TRACE enabled.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24414 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-03-16 22:18:32 +00:00
Ingo Weinhold
404a0fea46 Second stab at reorganizing standard/gcc headers. This time it not only
builds on Linux with gcc 2 and 4, but the images do even run. :-) Not
tested on BeOS.

* Removed stddef.h and stdarg.h. They are provided by the compiler.
* Adjusted size_t.h, wchar_t.h, and wchar.h accordingly.
* Made stdio.h avoid gcc 2.95.3's fixincludes hack stdio_va_list
* Added gcc 2.95.3 headers to the repository. They are used instead of
  the headers of the gcc 2.95.3's we use to compile Haiku with. Should
  avoid build problems with the BeOS native compiler.

For sake of personal recreation you can rebuild the cross gcc 2.95.3,
but the only thing that changed is its header directory
(lib/gcc-lib/.../include), which isn't used anymore. Replacing it with
headers/build/gcc-2.95.3 should have the same effect as rebuilding, BTW.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24413 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-03-16 17:21:37 +00:00
Ingo Weinhold
0cfb40d0dc Define HUGE_VAL in <math.h> conditionally. That's what gcc's fixincludes
hack math_huge_val_ifndef does, anyway. We do it ourselves and remove
the therefore superfluous gcc math.h header.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24412 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-03-16 16:39:06 +00:00
Axel Dörfler
7a3ecb82ba * _SeekDown() now checks if it has already reached the maximum tree
depth, and will bail out if it hasn't reached the leaf level then.
* This should at least avoid the crash of bug #1911; there is not much
  more I can do about that.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24411 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-03-16 16:26:05 +00:00
Axel Dörfler
d89cda9ff7 * Fixed another big bug in the logging code: I obviously got confused
what RunArrays::Length() meant; it should have been the length of a
  log entry, but was only the block count.
* Now I've improved naming and fixed initializing the LogEntry with a 
  wrong size, causing subsequent log entries to lose track in the log
  (the log_start pointer got wrong, so BFS would not be able to replay
  such a log).
* This at least fixes one part of the problem of bug #1911.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24410 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-03-16 15:53:42 +00:00
Rene Gollent
1f83df03bc Implement save/restoring replicants in BShelf. This results in
Tracker now persisting its desktop replicants across sessions.
This may not completely handle zombies properly though, I had
nothing to test that case with.



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24409 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-03-16 05:55:25 +00:00
Ingo Weinhold
d8ce64a27f Reverted r24406. If it builds, it doesn't always work as well. The
change resulted in "version mismatch between boot loader and kernel". So
apparently the size of some type changed unintentionally.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24408 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-03-15 19:23:05 +00:00
Ingo Weinhold
5513309cb4 Use a union instead of the macro.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24407 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-03-15 18:49:48 +00:00
Ingo Weinhold
6191d9a8da * Removed our stddef.h. We don't need it, since gcc comes with one that
under Haiku overrides ours anyway.
* Adjusted size_t.h, wchar_t.h, wchar.h accordingly. This should fix the
  annoying "ssize_t redefined" warnings when compiling under Haiku.
* When building Haiku the gcc headers come first in the include
  search path now, as it should be. The respective TODO suggested that
  this might break the build depending on compiler version and host
  platform. I've tested with Linux gcc 2 and gcc 4, which work fine.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24406 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-03-15 18:41:46 +00:00
Michael Lotz
f4af1fba51 Use the empty_index field as the allocation_id for large allocations and just
use the index of the first page of the allocation as an id. This removes the
need for separate id generation. This also fixes the possible problem of
multiple large allocations getting the same allocation_id (due to the limited
range of possible ids), which in the worst case (i.e. for adjacent allocations)
could cause pages to be freed that were still in use.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24405 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-03-15 17:35:34 +00:00
Axel Dörfler
fe8b72bc69 Applied patch by Vasilis:
* Fixed various warnings with GCC4 due to the double sHaikuRevision line.
* Turned system_info.c to a C++ file.
* Minor cleanup.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24404 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-03-15 16:59:30 +00:00
Rene Gollent
e28ef85ab7 Unify the app signature used everywhere for the time prefs. This fixes dstcheck being unable to actually invoke the
time prefs if asked to adjust the clock.



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24403 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-03-15 16:44:10 +00:00
Axel Dörfler
772506f830 Divided the _ReplayRunArray() method into two passes: first, the integrity
of the blocks in the log entry will be checked, and only if this passed,
all log entries are written back together; if the whole run array contained
bad data, it's no longer written to disk at all if it's detectable.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24402 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-03-15 16:35:10 +00:00
Axel Dörfler
f426071223 * For whatever weird reason, BFS apparently restricts a log entry to 126
entries, even though many more could fit in the blog. This fixes mounting
  a dirty (original-)BFS volume with a block size larger than 1024 bytes,
  and probably vice versa.
* Minor cleanup.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24401 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-03-15 16:25:55 +00:00
Axel Dörfler
6cc5885822 * Improved error reporting when mounting a volume failed, especially when
the log couldn't be replayed.
* Minor cleanup.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24400 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-03-15 16:21:57 +00:00
Rene Gollent
5a32be6b84 Specify a umask when creating tracker_shelf file.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24399 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-03-15 16:19:03 +00:00
Oliver Ruiz Dorantes
b4825b618a Remove code references for commands
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24398 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-03-15 15:46:58 +00:00
Oliver Ruiz Dorantes
0ba3dcf529 Mark to fix in some other moment
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24397 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-03-15 15:34:39 +00:00
Axel Dörfler
6107b24def * Changed the sorting order back to how it was done previously to r22113.
* This fixes bug #1915.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24396 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-03-15 15:20:49 +00:00
Axel Dörfler
569e90b022 Applied patch by Curtis Wanner: corrects wchar_t handling, and removes a
warning (SIZE_MAX was redefined).


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24395 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-03-15 11:16:57 +00:00
Axel Dörfler
b921611458 Applied patch by Vasilis - thanks!
* fixed compilation warnings in Node.h and NodeRef.h.
* Added license header to NodeRef.h.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24394 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-03-15 10:45:53 +00:00
Ingo Weinhold
fae99f156e cached_block::Compare() was ignoring the upper 32 bit of the block
number. Was a problem only for partitions > 2^32 * block size (4TB
for 1KB blocks).


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24393 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-03-14 22:03:26 +00:00
Ingo Weinhold
6044b22ddb Added new macro SYSCALL_TRACING_IGNORE_KTRACE_OUTPUT to disable tracing
for the _kern_ktrace_output() syscall.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24392 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-03-14 21:58:17 +00:00
François Revol
929c94fe37 This should fix R5 BONE build, as it also lacks setenv(), unlike dano.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24391 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-03-14 16:30:52 +00:00
Axel Dörfler
d8ebe61203 The fWorkspacesViews list now gets its own lock which solves a deadlock
problem when deleting Workspaces replicants.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24390 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-03-14 13:21:17 +00:00
Axel Dörfler
ac2042cb70 * Moved about window into the view and made it accessible from the
replicant as well.
* Added a context menu that allows you to change how Workspaces looks
  and behaves (previously accessible only using command line options).
* The settings changes are now remembered; we're now using a new 
  settings file (flattened BMessage), but can still read old settings 
  files if it exists.
* Renamed WorkspacesPreferences to WorkspacesSettings.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24389 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-03-14 13:14:23 +00:00
Axel Dörfler
58c42ec9de No need for the kWorkspacesWindow flag anymore.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24388 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-03-14 11:19:57 +00:00
Axel Dörfler
97b3cb2672 * Workspaces can now be a replicant.
* The view must be a follow all view since the workspaces are handled
  differently.
* No longer needs to use kWorkspacesWindowFlag; this makes it no longer
  work on BeOS.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24387 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-03-14 11:14:44 +00:00
Ingo Weinhold
2b0b4bee36 store_acquire_unreferenced_ref() saves the pointer of the vnode it got
from the call to vfs_get_vnode() now. Only this way it is safe to call
store_release_ref() later (as the page writer does). We had a potential
race condition -- if called after vm_cache_remove_consumer() had
released the last reference, the old vnode might already have been
deleted.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24386 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-03-13 23:41:14 +00:00
Oliver Ruiz Dorantes
23234fa59d Supply a supoprt file for functions used among all the kit
Move implementation from LocalDevice for retrieving the BluetoothServer Messenger



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24385 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-03-13 20:13:39 +00:00
Oliver Ruiz Dorantes
057d0dc02a Correct misspell adquire->acquire
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24384 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-03-13 19:30:04 +00:00
Axel Dörfler
30f55bc990 * Rewrote widget output path discovery, it's now very similar to what the
FreeBSD driver is doing.
* hda_codec_new_audio_group() did not free the audio group's widgets on
  failure.
* No longer create the input stream for now.
* Reworked multiaudio-support to work regardless if there is only a playback
  or record stream.
* With these changes, I hear nothing on my laptop anymore (before there was
  noise), but on another system, I can finally hear something that sounds very
  much like the sinus wave the multi_audio_test application produces; the
  sound quality is pretty bad though (lots of periodical noise and glitches).
* Made B_MULTI_GET_DESCRIPTION safe to be called from userland.
* Minor other cleanup.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24383 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-03-13 12:25:29 +00:00
Marcus Overhagen
4ca14fe1a6 Fixed harmless copy & paste bug.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24382 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-03-12 23:19:52 +00:00
Axel Dörfler
0dc57dbece The log replay code now checks if a super block is valid before the current
one gets overwritten; if the log contains invalid data, it will no longer
render the whole disk unreadable. This should have helped to prevent bug #1911
(but of course the problem that there is invalid data in the log in the first
place remains).


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24381 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-03-12 22:49:41 +00:00
Oliver Ruiz Dorantes
876b8c17c8 Remove Command builder implementation from the server
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24380 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-03-12 21:52:49 +00:00
Oliver Ruiz Dorantes
32c01b554a Move the command builder module to the kit although meant to be kept private
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24379 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-03-12 21:44:25 +00:00
Jérôme Duval
7578c0049e fix warnings
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24378 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-03-12 21:43:13 +00:00
Jérôme Duval
90e536bc49 fix the build, hope it works :)
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24377 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-03-12 21:29:50 +00:00