Index: trunk/i386/libsaio/xml.c =================================================================== --- trunk/i386/libsaio/xml.c (revision 1020) +++ trunk/i386/libsaio/xml.c (revision 1021) @@ -355,7 +355,7 @@ else { printf("ParseStringID error (0x%x)\n", *val); - getchar(); + getc(); //Azi: getchar(); return -1; } } @@ -380,7 +380,7 @@ else { printf("ParseStringIDREF error (0x%x)\n", *val); - getchar(); + getc(); //Azi: getchar(); return -1; } } @@ -423,7 +423,7 @@ else { printf("ParseIntegerID error (0x%x)\n", *val); - getchar(); + getc(); //Azi: getchar(); return -1; } } @@ -448,7 +448,7 @@ else { printf("ParseStringIDREF error (0x%x)\n", *val); - getchar(); + getc(); //Azi: getchar(); return -1; } } @@ -669,7 +669,7 @@ if(buffer[0] == '<') { printf("Warning integer is non existant\n"); - getchar(); + getc(); //Azi: getchar(); tmpTag = NewTag(); tmpTag->type = kTagTypeInteger; tmpTag->string = 0; @@ -710,7 +710,7 @@ else { printf("ParseTagInteger hex error (0x%x) in buffer %s\n", *val, buffer); - getchar(); + getc(); //Azi: getchar(); return -1; } } @@ -731,7 +731,7 @@ if (*val < '0' || *val > '9') { printf("ParseTagInteger decimal error (0x%x) in buffer %s\n", *val, buffer); - getchar(); + getc(); //Azi: getchar(); return -1; } @@ -771,7 +771,7 @@ //printf("ParseTagData unimplimented\n"); //printf("Data: %s\n", buffer); - // getchar(); + // getc(); //Azi: getchar(); // TODO: base64 decode @@ -803,7 +803,7 @@ if (tmpTag == 0) return -1; printf("ParseTagDate unimplimented\n"); - getchar(); + getc(); //Azi: getchar(); tmpTag->type = kTagTypeDate; tmpTag->string = 0; Index: trunk/i386/libsaio/console.c =================================================================== --- trunk/i386/libsaio/console.c (revision 1020) +++ trunk/i386/libsaio/console.c (revision 1021) @@ -158,13 +158,13 @@ // Read and echo a character from console. This doesn't echo backspace // since that screws up higher level handling -int getchar() +int getchar() //Azi: study!!! { register int c = getc(); - if ( c == '\r' ) c = '\n'; + if ( c == '\r' ) c = '\n'; //Azi: CR/LF ?? - if ( c >= ' ' && c < 0x7f) putchar(c); + if ( c >= ' ' && c < 0x7f) putchar(c); //Azi: check gui.h - kReturnKey, etc... return (c); } @@ -263,6 +263,6 @@ void pause() { printf("Press a key to continue...\n"); - getchar(); //getc(); //Azi: getc works here because the function is up above; changed for now. - // replace getchar() by pause() ?? + getc(); //getchar(); //Azi: getc works here because the function is up above. + // replace get/getchar by pause() ?? } Index: trunk/i386/libsaio/acpi_patcher.c =================================================================== --- trunk/i386/libsaio/acpi_patcher.c (revision 1020) +++ trunk/i386/libsaio/acpi_patcher.c (revision 1021) @@ -1058,7 +1058,7 @@ } #if DEBUG_ACPI printf("Press a key to continue... (DEBUG_ACPI)\n"); - getchar(); + getc(); //Azi: getchar(); #endif return 1; } Index: trunk/i386/libsaio/load.c =================================================================== --- trunk/i386/libsaio/load.c (revision 1020) +++ trunk/i386/libsaio/load.c (revision 1021) @@ -135,7 +135,7 @@ printf("ncmds: %x\n", (unsigned)mH->ncmds); printf("sizeofcmds: %x\n", (unsigned)mH->sizeofcmds); printf("flags: %x\n", (unsigned)mH->flags); - getchar(); + getc(); //Azi: getchar();; #endif ncmds = mH->ncmds; @@ -219,7 +219,7 @@ printf("segname: %s, vmaddr: %x, vmsize: %x, fileoff: %x, filesize: %x, nsects: %d, flags: %x.\n", segCmd->segname, (unsigned)vmaddr, (unsigned)vmsize, (unsigned)fileaddr, (unsigned)filesize, (unsigned) segCmd->nsects, (unsigned)segCmd->flags); - getchar(); + getc(); //Azi: getchar(); #endif } else @@ -239,7 +239,7 @@ printf("segname: %s, vmaddr: %x, vmsize: %x, fileoff: %x, filesize: %x, nsects: %d, flags: %x.\n", segCmd->segname, (unsigned)vmaddr, (unsigned)vmsize, (unsigned)fileaddr, (unsigned)filesize, (unsigned) segCmd->nsects, (unsigned)segCmd->flags); - getchar(); + getc(); //Azi: getchar(); #endif } @@ -317,7 +317,7 @@ #if DEBUG printf("symoff: %x, nsyms: %x, stroff: %x, strsize: %x\n", symTab->symoff, symTab->nsyms, symTab->stroff, symTab->strsize); - getchar(); + getc(); //Azi: getchar(); #endif symsSize = symTab->stroff - symTab->symoff; Index: trunk/i386/libsaio/disk.c =================================================================== --- trunk/i386/libsaio/disk.c (revision 1020) +++ trunk/i386/libsaio/disk.c (revision 1021) @@ -1636,7 +1636,7 @@ printf(" bvr: %d, dev: %d, part: %d, flags: %d, vis: %d\n", bvr, bvr->biosdev, bvr->part_no, bvr->flags, bvr->visible); } printf("count: %d\n", bvCount); - getchar(); + getc(); //Azi: getchar(); #endif *count = bvCount; Index: trunk/i386/libsaio/hpet.c =================================================================== --- trunk/i386/libsaio/hpet.c (revision 1020) +++ trunk/i386/libsaio/hpet.c (revision 1021) @@ -98,6 +98,6 @@ #if DEBUG_HPET printf("Press [Enter] to continue...\n"); - getchar(); + getc(); //Azi: getchar(); #endif } Index: trunk/i386/libsaio/biosfn.c =================================================================== --- trunk/i386/libsaio/biosfn.c (revision 1020) +++ trunk/i386/libsaio/biosfn.c (revision 1021) @@ -185,7 +185,7 @@ // Some BIOSes will simply ignore the value of ECX on entry. // Probably best to keep its value at 20 to avoid surprises. - //printf("Get memory map 0x%x, %d\n", rangeArray); getchar(); + //printf("Get memory map 0x%x, %d\n", rangeArray); getc(); //Azi: getchar(); if (maxRangeCount > (BIOS_LEN / sizeof(MemoryRange))) { maxRangeCount = (BIOS_LEN / sizeof(MemoryRange)); } @@ -252,10 +252,10 @@ #if DEBUG { int i; - printf("%d total ranges\n", count); getchar(); + printf("%d total ranges\n", count); getc(); //Azi: getchar(); for (i=0, range = rangeArray; itype, (unsigned int)range->base, (unsigned int)range->length); getchar(); + range->type, (unsigned int)range->base, (unsigned int)range->length); getc(); //Azi: getchar(); } } #endif @@ -509,7 +509,8 @@ printf("media_type: %x\n", pkt.media_type); printf("drive_num: %x\n", pkt.drive_num); printf("device_spec: %x\n", pkt.device_spec); - printf("press a key->\n"); getchar(); +// printf("press a key->\n"); getc(); //Azi: getchar(); + pause(); #endif /* Some BIOSes erroneously return cf = 1 */ @@ -675,7 +676,8 @@ print_drive_info(di); printf("uses_ebios = 0x%x\n", dp->uses_ebios); printf("result %d\n", ret); - printf("press a key->\n"); getchar(); +// printf("press a key->\n"); getc(); //Azi: getchar(); + pause(); #endif if (ret == 0) { Index: trunk/i386/libsaio/saio_internal.h =================================================================== --- trunk/i386/libsaio/saio_internal.h (revision 1020) +++ trunk/i386/libsaio/saio_internal.h (revision 1021) @@ -49,7 +49,8 @@ extern int ebiosEjectMedia(int biosdev); extern void bios_putchar(int ch); extern void putca(int ch, int attr, int repeat); -extern void pause(); +extern int getc(void); //Azi: getchar(); +extern void pause(); //Azi: replace getc/getchar with ? console.c - btw, what is it doing here ?? there's a console.c section below... extern int readKeyboardStatus(void); extern int readKeyboardShiftFlags(void); extern unsigned int time18(void); Index: trunk/i386/boot2/Makefile =================================================================== --- trunk/i386/boot2/Makefile (revision 1020) +++ trunk/i386/boot2/Makefile (revision 1021) @@ -125,7 +125,7 @@ endif - # this is done in a sub process after boot.sys exists so the strings are populated correctly + @# this is done in a sub process after boot.sys exists so the strings are populated correctly @make embed_symbols @${RM} $(SYMROOT)/boot2.sys Index: trunk/i386/boot2/resume.c =================================================================== --- trunk/i386/boot2/resume.c (revision 1020) +++ trunk/i386/boot2/resume.c (revision 1021) @@ -119,7 +119,7 @@ printf ("Resuming from Encrypted image is unsupported.\n" "Uncheck \"Use secure virtual memory\" in \"Security\" pane on system preferences.\n" "Press any key to proceed with normal boot.\n"); - getchar (); + getc(); //Azi: getchar(); return; } // depends on NVRAM @@ -143,7 +143,7 @@ if (!((long long)mem_base+allocSize<1024*bootInfo->extmem+0x100000)) { printf ("Not enough space to restore image. Press any key to proceed with normal boot.\n"); - getchar (); + getc(); //Azi: getchar(); return; } Index: trunk/i386/boot2/boot.c =================================================================== --- trunk/i386/boot2/boot.c (revision 1020) +++ trunk/i386/boot2/boot.c (revision 1021) @@ -185,7 +185,7 @@ bool dummyVal; if (getBoolForKey(kWaitForKeypressKey, &dummyVal, &bootInfo->bootConfig) && dummyVal) { printf("Press any key to continue..."); - getchar(); + getc(); //Azi: getchar(); } usb_loop(); @@ -350,7 +350,7 @@ #if DEBUG printf(" Default: %d, ->biosdev: %d, ->part_no: %d ->flags: %d\n", gBootVolume, gBootVolume->biosdev, gBootVolume->part_no, gBootVolume->flags); printf(" bt(0,0): %d, ->biosdev: %d, ->part_no: %d ->flags: %d\n", gBIOSBootVolume, gBIOSBootVolume->biosdev, gBIOSBootVolume->part_no, gBIOSBootVolume->flags); - getchar(); + getc(); //Azi: getchar(); #endif useGUI = true; Index: trunk/i386/boot2/boot.h =================================================================== --- trunk/i386/boot2/boot.h (revision 1020) +++ trunk/i386/boot2/boot.h (revision 1021) @@ -98,8 +98,8 @@ #define kUseNvidiaROM "UseNvidiaROM" /* nvidia.c */ #define kVBIOS "VBIOS" /* nvidia.c */ -#define kdcfg0 "display_0" /* nvidia.c */ -#define kdcfg1 "display_1" /* nvidia.c */ +#define kdcfg0 "display_0" /* nvidia.c */ +#define kdcfg1 "display_1" /* nvidia.c */ #define kEthernetBuiltIn "EthernetBuiltIn" /* pci_setup.c */ #define kGraphicsEnabler "GraphicsEnabler" /* pci_setup.c */ Index: trunk/i386/boot2/modules.c =================================================================== --- trunk/i386/boot2/modules.c (revision 1020) +++ trunk/i386/boot2/modules.c (revision 1021) @@ -16,7 +16,7 @@ #if CONFIG_MODULE_DEBUG #define DBG(x...) printf(x); -#define DBGPAUSE() getchar() +#define DBGPAUSE() getc() // getchar(); #else #define DBG(x...) #define DBGPAUSE() @@ -86,7 +86,7 @@ else { // The module does not have a valid start function - printf("Unable to start %s\n", SYMBOLS_MODULE); getchar(); + printf("Unable to start %s\n", SYMBOLS_MODULE); getc(); //Azi: getchar(); } } } @@ -185,7 +185,7 @@ else // The module does not have a valid start function. This may be a library. { printf("WARNING: Unable to start %s\n", module); - getchar(); + getc(); //Azi: getchar(); } #else else msglog("WARNING: Unable to start %s\n", module); @@ -304,7 +304,7 @@ #if CONFIG_MODULE_DEBUG printf("Unable to locate symbol %s\n", name); - getchar(); + getc(); //Azi: getchar(); #endif if(strcmp(name, VOID_SYMBOL) == 0) return 0xFFFFFFFF; @@ -370,7 +370,7 @@ else { verbose("Invalid mach magic 0x%X\n", ((struct mach_header*)binary)->magic); - //getchar(); + //getc(); //Azi: getchar(); return NULL; } @@ -379,7 +379,7 @@ /*if(((struct mach_header*)binary)->filetype != MH_DYLIB) { printf("Module is not a dylib. Unable to load.\n"); - getchar(); + getc(); //Azi: getchar(); return NULL; // Module is in the incorrect format }*/ @@ -891,7 +891,7 @@ else { printf("Unable to bind symbol %s\n", symbolName); - getchar(); + getc(); //Azi: getchar(); } segmentAddress += sizeof(void*); @@ -910,7 +910,7 @@ else { printf("Unable to bind symbol %s\n", symbolName); - getchar(); + getc(); //Azi: getchar(); } segmentAddress += tmp + sizeof(void*); @@ -928,7 +928,7 @@ else { printf("Unable to bind symbol %s\n", symbolName); - getchar(); + getc(); //Azi: getchar(); } segmentAddress += (immediate * sizeof(void*)) + sizeof(void*); @@ -953,7 +953,7 @@ else { printf("Unable to bind symbol %s\n", symbolName); - getchar(); + getc(); //Azi: getchar(); } break; } @@ -1085,7 +1085,7 @@ #if CONFIG_MODULE_DEBUG //print_hook_list(); - //getchar(); + //getc(); //Azi: getchar(); #endif } @@ -1133,7 +1133,7 @@ void dyld_stub_binder() { printf("ERROR: dyld_stub_binder was called, should have been take care of by the linker.\n"); - getchar(); + getc(); //Azi: getchar(); } #else /* CONFIG_MODULES */ Index: trunk/i386/boot2/gui.c =================================================================== --- trunk/i386/boot2/gui.c (revision 1020) +++ trunk/i386/boot2/gui.c (revision 1021) @@ -142,9 +142,11 @@ extern MenuItem *menuItems; -//char prompt[BOOT_STRING_LEN]; -extern char gBootArgs[BOOT_STRING_LEN]; +char prompt[BOOT_STRING_LEN]; +//extern char gBootArgs[BOOT_STRING_LEN]; //Azi: getchar/prompt stuff +int prompt_pos = 0; + char prompt_text[] = "boot: "; menuitem_t infoMenuItems[] = @@ -910,8 +912,8 @@ void clearGraphicBootPrompt() { // clear text buffer - //prompt[0] = '\0'; - //prompt_pos=0; + prompt[0] = '\0'; //Azi: getchar/prompt stuff + prompt_pos=0; if( gui.bootprompt.draw == true ) @@ -927,6 +929,15 @@ void updateGraphicBootPrompt(int key) { + if ( key == kBackspaceKey ) //Azi: getchar/prompt stuff + prompt[--prompt_pos] = '\0'; + else + { + prompt[prompt_pos] = key; + prompt_pos++; + prompt[prompt_pos] = '\0'; + } + fillPixmapWithColor( gui.bootprompt.pixmap, gui.bootprompt.bgcolor); makeRoundedCorners( gui.bootprompt.pixmap); @@ -938,14 +949,16 @@ // get the position of the end of the boot prompt text to display user input position_t p_prompt = pos( p_text.x + ( ( strlen(prompt_text) ) * font_console.chars[0]->width ), p_text.y ); - +//Azi: getchar/prompt stuff // calculate the position of the cursor - int offset = ( strlen(gBootArgs) - ( ( gui.bootprompt.width / font_console.chars[0]->width ) - strlen(prompt_text) - 2 ) ); - + int offset = ( prompt_pos - ( ( gui.bootprompt.width / font_console.chars[0]->width ) - strlen(prompt_text) - 2 ) ); + if ( offset < 0) offset = 0; - drawStr( gBootArgs, &font_console, gui.bootprompt.pixmap, p_prompt); + drawStr( prompt+offset, &font_console, gui.bootprompt.pixmap, p_prompt); +// end + drawStr( prompt + offset, &font_console, gui.bootprompt.pixmap, p_prompt); gui.menu.draw = false; gui.bootprompt.draw = true; @@ -1569,7 +1582,7 @@ updateVRAM(); - key = getchar(); + key = getc(); //Azi: getchar(); if( key == kUpArrowkey ) if( currentline > 0 ) Index: trunk/i386/boot2/gui.h =================================================================== --- trunk/i386/boot2/gui.h (revision 1020) +++ trunk/i386/boot2/gui.h (revision 1021) @@ -1,10 +1,10 @@ /* - * gui.h - * + * gui.h + * * - * Created by Jasmin Fazlic on 18.12.08. - * Copyright 2008/09 Jasmin Fazlic All rights reserved. - * Copyright 2008/09 iNDi All rights reserved. + * Created by Jasmin Fazlic on 18.12.08. + * Copyright 2008/09 Jasmin Fazlic All rights reserved. + * Copyright 2008/09 iNDi All rights reserved. * */ @@ -19,35 +19,35 @@ #define CHARACTERS_COUNT 223 -#define BOOT_NORMAL 0 +#define BOOT_NORMAL 0 #define BOOT_VERBOSE 1 #define BOOT_IGNORECACHE 2 #define BOOT_SINGLEUSER 3 -#define DO_NOT_BOOT 4 +#define DO_NOT_BOOT 4 #define CLOSE_INFO_MENU 5 -#define INFOMENU_NATIVEBOOT_START 1 -#define INFOMENU_NATIVEBOOT_END 3 +#define INFOMENU_NATIVEBOOT_START 1 +#define INFOMENU_NATIVEBOOT_END 3 -#define MENU_SHOW_MEMORY_INFO 4 -#define MENU_SHOW_VIDEO_INFO 5 -#define MENU_SHOW_HELP 6 +#define MENU_SHOW_MEMORY_INFO 4 +#define MENU_SHOW_VIDEO_INFO 5 +#define MENU_SHOW_HELP 6 enum { HorizontalLayout = 0, - VerticalLayout = 1, + VerticalLayout = 1 }; enum { kBackspaceKey = 0x08, - kTabKey = 0x09, - kReturnKey = '\n', - kEscapeKey = 0x1b, - kUpArrowkey = 0x4800, + kTabKey = 0x09, + kReturnKey = 0x0d, // '\n', //Azi: r926 + kEscapeKey = 0x1b, + kUpArrowkey = 0x4800, kDownArrowkey = 0x5000, - kASCIIKeyMask = 0x7f, - kF5Key = 0x3f00, - kF10Key = 0x4400 + kASCIIKeyMask = 0x7f, //Azi: getchar()*** + kF5Key = 0x3f00, + kF10Key = 0x4400 }; /* Index: trunk/i386/boot2/ramdisk.c =================================================================== --- trunk/i386/boot2/ramdisk.c (revision 1020) +++ trunk/i386/boot2/ramdisk.c (revision 1021) @@ -290,7 +290,7 @@ setCursorPosition(0, 0, 1); showInfoRAMDisk(); printf("\n\nPress any key to continue.\n"); - getchar(); + getc(); //Azi: getchar(); setActiveDisplayPage(0); } else @@ -303,7 +303,7 @@ printf("\n?rd m - mount ramdisk image\n?rd u - unmount ramdisk image"); printf("\n?rd e - enable bt(0,0) alias\n?rd d - disable bt(0,0) alias"); printf("\n\nPress any key to continue.\n"); - getchar(); + getc(); //Azi: getchar(); setActiveDisplayPage(0); } } Index: trunk/i386/boot2/options.c =================================================================== --- trunk/i386/boot2/options.c (revision 1020) +++ trunk/i386/boot2/options.c (revision 1021) @@ -172,7 +172,8 @@ //========================================================================== -char gBootArgs[BOOT_STRING_LEN]; +//char gBootArgs[BOOT_STRING_LEN]; +static char gBootArgs[BOOT_STRING_LEN]; static char * gBootArgsPtr = gBootArgs; static char * gBootArgsEnd = gBootArgs + BOOT_STRING_LEN - 1; static char booterCommand[BOOT_STRING_LEN]; @@ -205,12 +206,13 @@ extern char bootPrompt[]; extern char bootRescanPrompt[]; - if( bootArgs->Video.v_display == VGA_TEXT_MODE ) { - changeCursor( strlen(gBootArgs), row, kCursorTypeUnderline, 0 ); - //clearScreenRows( row, kScreenLastRow ); + if ( bootArgs->Video.v_display == VGA_TEXT_MODE ) { +//Azi: getchar/prompt stuff + changeCursor( 0, row, kCursorTypeUnderline, 0 ); + clearScreenRows( row, kScreenLastRow ); } - //clearBootArgs(); + clearBootArgs(); if (visible) { if (bootArgs->Video.v_display == VGA_TEXT_MODE) { @@ -218,12 +220,13 @@ printf( bootRescanPrompt ); } else { printf( bootPrompt ); - printf( gBootArgs ); +// printf( gBootArgs ); } } } else { if (bootArgs->Video.v_display == GRAPHICS_MODE) { -// clearGraphicBootPrompt(); + clearGraphicBootPrompt(); +// End } else { printf("Press Enter to start up the foreign OS. "); } @@ -237,7 +240,7 @@ key &= kASCIIKeyMask; switch ( key ) - { + { case kBackspaceKey: if ( gBootArgsPtr > gBootArgs ) { @@ -253,27 +256,26 @@ { setCursorPosition( x, y, 0 ); putca(' ', 0x07, 1); - } - - *gBootArgsPtr-- = '\0'; - updateGraphicBootPrompt(kBackspaceKey); - } - else - { - *gBootArgsPtr = '\0'; - if( bootArgs->Video.v_display == VGA_TEXT_MODE ) putca(' ', 0x07, 1); - updateGraphicBootPrompt(kBackspaceKey); - } - +//Azi: getchar/prompt stuff + } else + updateGraphicBootPrompt(kBackspaceKey); + + *gBootArgsPtr-- = '\0'; + } + break; default: if ( key >= ' ' && gBootArgsPtr < gBootArgsEnd) { - *gBootArgsPtr++ = key; - updateGraphicBootPrompt(key); + if( bootArgs->Video.v_display == VGA_TEXT_MODE ) + putchar(key); // echo to screen + else + updateGraphicBootPrompt(key); + *gBootArgsPtr++ = key; +// end } - + break; } } @@ -915,7 +917,7 @@ // reset cursor co-ords gui.debug.cursor = pos( gui.screen.width - 160 , 10 ); } - key = getchar(); + key = getc(); //Azi: getchar(); updateMenu( key, (void **) &menuBVR ); newShowPrompt = (gDeviceCount == 0) || (menuBVR->flags & kBVFlagNativeBoot); @@ -1387,7 +1389,7 @@ printf("[Type %s%sq to quit viewer]", (line_offset > 0) ? "p for previous page, " : "", (*bp != '\1') ? "space for next page, " : ""); } - c = getchar(); + c = getc(); //Azi: getchar(); if (c == 'q' || c == 'Q') { break; } @@ -1454,7 +1456,7 @@ printf("Typical boot devices are 80 (First HD), 81 (Second HD)\n"); printf("Enter two-digit hexadecimal boot device [%02x]: ", bootdevice); do { - key = getchar(); + key = getc(); //Azi: getchar(); switch (key & kASCIIKeyMask) { case kBackspaceKey: if (digitsI > 0) { @@ -1505,7 +1507,7 @@ bool promptForRescanOption(void) { printf("\nWould you like to enable media rescan option?\nPress ENTER to enable or any key to skip.\n"); - if (getchar() == kReturnKey) { + if (getc() == kReturnKey) { //Azi: getchar(); return true; } else { return false; Index: trunk/i386/modules/HelloWorld/HelloWorld.cpp =================================================================== --- trunk/i386/modules/HelloWorld/HelloWorld.cpp (revision 1020) +++ trunk/i386/modules/HelloWorld/HelloWorld.cpp (revision 1021) @@ -35,10 +35,7 @@ delete obj2; printf("Hello world from ExecKernel hook. Binary located at 0x%X\n", binary); - getchar(); - - // - + getc(); //Azi: getchar(); ?? } void HelloWorld_start() @@ -46,7 +43,6 @@ //printf("Hooking 'ExecKernel'\n"); register_hook_callback("ExecKernel", &helloWorld); register_hook_callback("Kernel Start", &helloWorld); - } void HW::printHello() Index: trunk/i386/libsa/libsa.h =================================================================== --- trunk/i386/libsa/libsa.h (revision 1020) +++ trunk/i386/libsa/libsa.h (revision 1021) @@ -93,7 +93,7 @@ extern int strncmp(const char * s1, const char * s2, size_t n); extern char * strcpy(char * s1, const char * s2); extern char * strncpy(char * s1, const char * s2, size_t n); -extern size_t strlcpy(char * s1, const char * s2, size_t n); +extern size_t strlcpy(char * s1, const char * s2, size_t n); //Azi: ?? check! extern char * strstr(const char *in, const char *str); extern int atoi(const char * str); extern int ptol(const char * str); Index: trunk/i386/libsa/string.c =================================================================== --- trunk/i386/libsa/string.c (revision 1020) +++ trunk/i386/libsa/string.c (revision 1021) @@ -166,7 +166,7 @@ } size_t -strlcpy(char * s1, const char * s2, size_t n) +strlcpy(char * s1, const char * s2, size_t n) //Azi: libsa.h { while (n && (*s1++ = *s2++)) n--; Index: trunk/i386/util/fdisk/misc.c =================================================================== --- trunk/i386/util/fdisk/misc.c (revision 1020) +++ trunk/i386/util/fdisk/misc.c (revision 1021) @@ -142,9 +142,9 @@ printf("%s [%c] ", str, default_answer ? 'y' : 'n'); fflush(stdout); - first = ch = getchar(); + first = ch = getchar(); //Azi: what about these ? while (ch != '\n' && ch != EOF) - ch = getchar(); + ch = getchar(); //Azi: not messing them :P if (ch == EOF || first == EOF) errx(1, "eof");