This fixes when I try to makebootable after building Haiku from Zeta.

I don't get "Error: Specifying directories not supported on this platform!" now.
Also includes some added \n.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@32011 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
Fredrik Modeen
2009-07-31 10:13:37 +00:00
parent 74b19566ee
commit 1d4673660f
@@ -163,12 +163,12 @@ read_boot_code_data(const char* programPath)
0, bootCodeData, kBootCodeSize); 0, bootCodeData, kBootCodeSize);
if (bytesRead < 0) { if (bytesRead < 0) {
fprintf(stderr, "Error: Failed to read boot code from resources " fprintf(stderr, "Error: Failed to read boot code from resources "
"or attribute."); "or attribute.\n");
exit(1); exit(1);
} }
if (bytesRead != kBootCodeSize) { if (bytesRead != kBootCodeSize) {
fprintf(stderr, "Error: Failed to read boot code from resources, " fprintf(stderr, "Error: Failed to read boot code from resources, "
"and the boot code in the attribute has the wrong size!"); "and the boot code in the attribute has the wrong size!\n");
exit(1); exit(1);
} }
} }
@@ -270,7 +270,7 @@ main(int argc, const char *const *argv)
bootCodeData = read_boot_code_data(info.name); bootCodeData = read_boot_code_data(info.name);
#endif #endif
if (!bootCodeData) { if (!bootCodeData) {
fprintf(stderr, "Error: Failed to read "); fprintf(stderr, "Error: Failed to read \n");
exit(1); exit(1);
} }
@@ -299,7 +299,7 @@ main(int argc, const char *const *argv)
int64 partitionOffset = 0; int64 partitionOffset = 0;
fs_info info; // needs to be here (we use the device name later) fs_info info; // needs to be here (we use the device name later)
if (S_ISDIR(st.st_mode)) { if (S_ISDIR(st.st_mode)) {
#ifdef __HAIKU__ #if defined(__BEOS__) || defined(__HAIKU__)
// a directory: get the device // a directory: get the device
error = fs_stat_dev(st.st_dev, &info); error = fs_stat_dev(st.st_dev, &info);
@@ -654,7 +654,7 @@ main(int argc, const char *const *argv)
close(mountFD); close(mountFD);
} else { } else {
fprintf(stderr, "Could not update BFS boot code while the " fprintf(stderr, "Could not update BFS boot code while the "
"partition is mounted!"); "partition is mounted!\n");
} }
} }
#endif // __HAIKU__ #endif // __HAIKU__