Changeset bd29f9c9 in mainline for uspace/lib
- Timestamp:
- 2012-07-30T20:01:02Z (13 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 542e819, beb9336
- Parents:
- c15849c (diff), 597b12e (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the(diff)links above to see all the changes relative to each parent. - Location:
- uspace/lib
- Files:
-
- 12 edited
-
c/arch/abs32le/_link.ld.in (modified) (1 diff)
-
c/arch/amd64/_link.ld.in (modified) (1 diff)
-
c/arch/arm32/_link.ld.in (modified) (1 diff)
-
c/arch/ia32/_link.ld.in (modified) (2 diffs)
-
c/arch/ia64/_link.ld.in (modified) (2 diffs)
-
c/arch/mips32/_link.ld.in (modified) (1 diff)
-
c/arch/mips64/_link.ld.in (modified) (1 diff)
-
c/arch/ppc32/_link.ld.in (modified) (1 diff)
-
c/arch/sparc64/_link.ld.in (modified) (1 diff)
-
c/generic/str.c (modified) (3 diffs)
-
c/include/str.h (modified) (1 diff)
-
clui/tinput.c (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
uspace/lib/c/arch/abs32le/_link.ld.in
rc15849c rbd29f9c9 14 14 SECTIONS { 15 15 #ifdef LOADER 16 . = 0x70001000 + SIZEOF_HEADERS; 17 16 18 .interp : { 17 19 *(.interp); 18 } :interp 19 20 . = 0x70001000 + SIZEOF_HEADERS; 20 } :interp :text 21 21 #else 22 22 . = 0x1000 + SIZEOF_HEADERS; 23 23 #endif 24 24 25 .text : { 25 26 *(.text .text.*); -
uspace/lib/c/arch/amd64/_link.ld.in
rc15849c rbd29f9c9 15 15 SECTIONS { 16 16 #ifdef LOADER 17 . = 0x70001000 + SIZEOF_HEADERS; 18 17 19 .interp : { 18 20 *(.interp); 19 } :interp 20 21 . = 0x70001000 + SIZEOF_HEADERS; 21 } :interp :text 22 22 #else 23 23 . = 0x1000 + SIZEOF_HEADERS; 24 24 #endif 25 25 26 .init : { 26 27 *(.init); -
uspace/lib/c/arch/arm32/_link.ld.in
rc15849c rbd29f9c9 14 14 SECTIONS { 15 15 #ifdef LOADER 16 . = 0x70001000 + SIZEOF_HEADERS; 17 16 18 .interp : { 17 19 *(.interp); 18 } :interp 19 20 . = 0x70001000 + SIZEOF_HEADERS; 20 } :interp :text 21 21 #else 22 22 . = 0x1000 + SIZEOF_HEADERS; 23 23 #endif 24 24 25 .init : { 25 26 *(.init); -
uspace/lib/c/arch/ia32/_link.ld.in
rc15849c rbd29f9c9 19 19 20 20 SECTIONS { 21 #if defined(LOADER) || defined(DLEXE)22 .interp : {23 *(.interp);24 } :interp25 #endif26 21 #ifdef LOADER 27 22 . = 0x70001000 + SIZEOF_HEADERS; … … 29 24 . = 0x1000 + SIZEOF_HEADERS; 30 25 #endif 26 27 #if defined(LOADER) || defined(DLEXE) 28 .interp : { 29 *(.interp); 30 } :interp :text 31 #endif 32 31 33 .init : { 32 34 *(.init); -
uspace/lib/c/arch/ia64/_link.ld.in
rc15849c rbd29f9c9 14 14 SECTIONS { 15 15 #ifdef LOADER 16 . = 0x800000000 + SIZEOF_HEADERS; 17 16 18 .interp : { 17 19 *(.interp); 18 } :interp 19 20 . = 0x800000000 + SIZEOF_HEADERS; 20 } :interp :text 21 21 #else 22 22 . = 0x4000 + SIZEOF_HEADERS; 23 23 #endif 24 24 25 /* 25 26 * XXX This is just a work around. Problem: .init section does not … … 27 28 */ 28 29 . = ALIGN(., 16); 29 30 30 31 .init : { 31 32 *(.init); -
uspace/lib/c/arch/mips32/_link.ld.in
rc15849c rbd29f9c9 14 14 SECTIONS { 15 15 #ifdef LOADER 16 . = 0x70004000 + SIZEOF_HEADERS; 17 16 18 .interp : { 17 19 *(.interp); 18 } :interp 19 20 . = 0x70004000 + SIZEOF_HEADERS; 20 } :interp :text 21 21 #else 22 22 . = 0x4000 + SIZEOF_HEADERS; 23 23 #endif 24 24 25 .init : { 25 26 *(.init); -
uspace/lib/c/arch/mips64/_link.ld.in
rc15849c rbd29f9c9 15 15 SECTIONS { 16 16 #ifdef LOADER 17 . = 0x70004000 + SIZEOF_HEADERS; 18 17 19 .interp : { 18 20 *(.interp); 19 } :interp 20 21 . = 0x70004000 + SIZEOF_HEADERS; 21 } :interp :text 22 22 #else 23 23 . = 0x4000 + SIZEOF_HEADERS; 24 24 #endif 25 25 26 .init : { 26 27 *(.init); -
uspace/lib/c/arch/ppc32/_link.ld.in
rc15849c rbd29f9c9 15 15 SECTIONS { 16 16 #ifdef LOADER 17 . = 0x70001000 + SIZEOF_HEADERS; 18 17 19 .interp : { 18 20 *(.interp); 19 } :interp 20 21 . = 0x70001000 + SIZEOF_HEADERS; 21 } :interp :text 22 22 #else 23 23 . = 0x1000 + SIZEOF_HEADERS; 24 24 #endif 25 25 26 .init : { 26 27 *(.init); -
uspace/lib/c/arch/sparc64/_link.ld.in
rc15849c rbd29f9c9 14 14 SECTIONS { 15 15 #ifdef LOADER 16 . = 0x70004000 + SIZEOF_HEADERS; 17 16 18 .interp : { 17 19 *(.interp); 18 } :interp 19 20 . = 0x70004000 + SIZEOF_HEADERS; 20 } :interp :text 21 21 #else 22 22 . = 0x4000 + SIZEOF_HEADERS; 23 23 #endif 24 24 25 .init : { 25 26 *(.init); -
uspace/lib/c/generic/str.c
rc15849c rbd29f9c9 428 428 * 429 429 * Do a char-by-char comparison of two NULL-terminated strings. 430 * The strings are considered equal iff they consist of the same 431 * characters on the minimum of their lengths. 430 * The strings are considered equal iff their length is equal 431 * and both strings consist of the same sequence of characters. 432 * 433 * A string is smaller than another string iff it is shorter or 434 * has a character with lower value at the first position where 435 * the strings differ. 432 436 * 433 437 * @param s1 First string to compare. … … 466 470 * 467 471 * Do a char-by-char comparison of two NULL-terminated strings. 468 * The strings are considered equal iff they consist of the same 469 * characters on the minimum of their lengths and the length limit. 472 * The strings are considered equal iff 473 * min(str_length(s1), max_len) == min(str_length(s2), max_len) 474 * and both strings consist of the same sequence of characters, 475 * up to max_len characters. 476 * 477 * A string is smaller than another string iff it is shorter or 478 * has a character with lower value at the first position where 479 * the strings differ, considering only first max_len characters. 470 480 * 471 481 * @param s1 First string to compare. … … 508 518 return 0; 509 519 520 } 521 522 /** Test whether p is a prefix of s. 523 * 524 * Do a char-by-char comparison of two NULL-terminated strings 525 * and determine if p is a prefix of s. 526 * 527 * @param s The string in which to look 528 * @param p The string to check if it is a prefix of s 529 * 530 * @return true iff p is prefix of s else false 531 * 532 */ 533 bool str_test_prefix(const char *s, const char *p) 534 { 535 wchar_t c1 = 0; 536 wchar_t c2 = 0; 537 538 size_t off1 = 0; 539 size_t off2 = 0; 540 541 while (true) { 542 c1 = str_decode(s, &off1, STR_NO_LIMIT); 543 c2 = str_decode(p, &off2, STR_NO_LIMIT); 544 545 if (c2 == 0) 546 return true; 547 548 if (c1 != c2) 549 return false; 550 551 if (c1 == 0) 552 break; 553 } 554 555 return false; 510 556 } 511 557 -
uspace/lib/c/include/str.h
rc15849c rbd29f9c9 79 79 extern int str_lcmp(const char *s1, const char *s2, size_t max_len); 80 80 81 extern bool str_test_prefix(const char *s, const char *p); 82 81 83 extern void str_cpy(char *dest, size_t size, const char *src); 82 84 extern void str_ncpy(char *dest, size_t size, const char *src, size_t n); -
uspace/lib/clui/tinput.c
rc15849c rbd29f9c9 601 601 602 602 unsigned int cols = max(1, (ti->con_cols + 1) / (max_length + 1)); 603 unsigned int col_width = ti->con_cols / cols; 603 unsigned int padding = 0; 604 if ((cols * max_length) + (cols - 1) < ti->con_cols) { 605 padding = ti->con_cols - (cols * max_length) - (cols - 1); 606 } 607 unsigned int col_width = max_length + padding / cols; 604 608 unsigned int rows = cnum / cols + ((cnum % cols) != 0); 605 609
Note:
See TracChangeset
for help on using the changeset viewer.
