Search Results

Search found 5378 results on 216 pages for 'spell checking'.

Page 7/216 | < Previous Page | 3 4 5 6 7 8 9 10 11 12 13 14  | Next Page >

  • I get an "serious errors while checking the disk drives for /boot" error while booting

    - by Vaios Argiropoulos
    I have just set up my new system by creating three partitions on a whole hard disk (/boot,/home,swap and /(root)) .I saw this article and now i am getting those errors and the system provide me with some options (I to ignore, S to skip mounting or M for manual recovery). I am forced to choose skip mounting because i don't know what manual recovery is. Despite the error i get i think that the system boots ok because i can use the system but this error is very annoying.

    Read the article

  • Checking For Empty Enumerations

    While spelunking in some code recently I saw a method that looked something like this: public void Foo<T>(IEnumerable<T> items) { if(items == null || items.Count() == 0) { // Warn about emptiness } } This method accepts a generic enumeration and then proceeds to check if the enumeration is null or empty. Do you see the potential problem with this code? Ill give you a hint, its this line: items.Count() == 0 Whats the problem? Well that line right there has the potential...Did you know that DotNetSlackers also publishes .net articles written by top known .net Authors? We already have over 80 articles in several categories including Silverlight. Take a look: here.

    Read the article

  • Checking collision of bullets and Asteroids

    - by Moaz ELdeen
    I'm trying to detect collision between two list of bullets and asteroids. The code works fine, but when the bullet intersects with an asteroid, and that bullet passes through another asteroid, the code gives an assertion, and it says about it can't increment the iterator. I'm sure there is a small bug in that code, but I can't find it. for (list<Bullet>::iterator itr_bullet = ship.m_Bullets.begin(); itr_bullet!=ship.m_Bullets.end();) { for (list<Asteroid>::iterator itr_astroid = asteroids.begin(); itr_astroid!=asteroids.end(); itr_astroid++) { if(checkCollision(itr_bullet->getCenter(),itr_astroid->getCenter(), itr_bullet->getRadius(), itr_astroid->getRadius())) { itr_astroid = asteroids.erase(itr_astroid); } } itr_bullet++; }

    Read the article

  • Checking validation of entries in a Sudoku game written in Java

    - by Mico0
    I'm building a simple Sudoku game in Java which is based on a matrix (an array[9][9]) and I need to validate my board state according to these rules: all rows have 1-9 digits all columns have 1-9 digits. each 3x3 grid has 1-9 digits. This function should be efficient as possible for example if first case is not valid I believe there's no need to check other cases and so on (correct me if I'm wrong). When I tried doing this I had a conflict. Should I do one large for loop and inside check columns and row (in two other loops) or should I do each test separately and verify every case by it's own? (Please don't suggest too advanced solutions with other class/object helpers.) This is what I thought about: Main validating function (which I want pretty clean): public boolean testBoard() { boolean isBoardValid = false; if (validRows()) { if (validColumns()) { if (validCube()) { isBoardValid = true; } } } return isBoardValid; } Different methods to do the specific test such as: private boolean validRows() { int rowsDigitsCount = 0; for (int num = 1; num <= 9; num++) { boolean foundDigit = false; for (int row = 0; (row < board.length) && (!foundDigit); row++) { for (int col = 0; col < board[row].length; col++) { if (board[row][col] == num) { rowsDigitsCount++; foundDigit = true; break; } } } } return rowsDigitsCount == 9 ? true : false; } I don't know if I should keep doing tests separately because it looks like I'm duplicating my code.

    Read the article

  • using "IS" is better or checking for "NOT NULL"

    - by BDotA
    In C#.NET language: This style of coding is recommended or the one below it? if (sheet.Models.Data is GroupDataModel) { GroupDataModel gdm = (GroupDataModel)sheet.Models.Data; Group group = gdm.GetGroup(sheet.ActiveCell.Row.Index); if (group!=null && controller != null) { controller.CheckApplicationState(); } } or this one: var gdm = sheet.Models.Data as GroupDataModel; if (gdm != null) { Group group = gdm.GetGroup(sheet.ActiveCell.Row.Index); if (@group!=null && controller != null) { controller.CheckApplicationState(); } }

    Read the article

  • How can I disable update checking on boot?

    - by Chauncellor
    I'm running off of a thumb drive with very average read/write speeds and automatic update checks makes the bootup far less pleasant. Since I manually update via apt there's truly no need to notify me like on a normal desktop. In older versions of Ubuntu there was an item to disable this behavior. On 12.04 this is no longer the case. would it be the 'unattended-upgrades' item in /etc/init.d? If yes, would simply removing the init script would solve my problem?

    Read the article

  • Checking a record is due based on the 'occuring' field

    - by andy
    I have records that have dates against them and an occurring field that contains none,yearly and monthly id status note date last_updated occurring 1 open --- 01/01/2011 01/02/2010 yearly 2 open --- 05/05/2011 03/05/2011 monthly 3 open --- 06/06/2011 05/06/2011 none Now I need to be able to check if a record is due (the date set has passed) which works perfect if occurring is set to none but I'm unsure of how to approach it when it's set to yearly or monthly (IE: This day in the year/month has passed) So with the above records, if I had a method on the record called due? providing the status is 'open' it needs to return true every year when it's passed that date if it's not been updated within the year yet. I apologise if this is confusing but it's melting my brain just trying to think of it, let alone put it into words.

    Read the article

  • How to Automate Checking for Stolen Content?

    - by Hisoka
    So I know about tools like Copyscape and Google Alerts.. great tools, but it's quite tedious for me to copy and paste an URL or phrase for every one of my pages in my sites. Is there any tool out there that monitors your website and emails you or alerts you whenever someone has stolen content from your site? The only service I know is CopySentry and honestly, it's too expensive for me since I got thousands of pages I want to monitor... Anyone else have this problem? or is it just me? Thanks for any help.

    Read the article

  • I can't install using Wubi due to permission denied error

    - by Taksh Sharma
    I can't install ubuntu 11.10 inside my windows 7. It shows permission denied while installation. It gave a log file having the following data: 03-29 20:19 DEBUG TaskList: # Running tasklist... 03-29 20:19 DEBUG TaskList: ## Running select_target_dir... 03-29 20:19 INFO WindowsBackend: Installing into D:\ubuntu 03-29 20:19 DEBUG TaskList: ## Finished select_target_dir 03-29 20:19 DEBUG TaskList: ## Running create_dir_structure... 03-29 20:19 DEBUG CommonBackend: Creating dir D:\ubuntu 03-29 20:19 DEBUG CommonBackend: Creating dir D:\ubuntu\disks 03-29 20:19 DEBUG CommonBackend: Creating dir D:\ubuntu\install 03-29 20:19 DEBUG CommonBackend: Creating dir D:\ubuntu\install\boot 03-29 20:19 DEBUG CommonBackend: Creating dir D:\ubuntu\disks\boot 03-29 20:19 DEBUG CommonBackend: Creating dir D:\ubuntu\disks\boot\grub 03-29 20:19 DEBUG CommonBackend: Creating dir D:\ubuntu\install\boot\grub 03-29 20:19 DEBUG TaskList: ## Finished create_dir_structure 03-29 20:19 DEBUG TaskList: ## Running uncompress_target_dir... 03-29 20:19 DEBUG TaskList: ## Finished uncompress_target_dir 03-29 20:19 DEBUG TaskList: ## Running create_uninstaller... 03-29 20:19 DEBUG WindowsBackend: Copying uninstaller E:\wubi.exe -> D:\ubuntu\uninstall-wubi.exe 03-29 20:19 DEBUG registry: Setting registry key -2147483646 Software\Microsoft\Windows\CurrentVersion\Uninstall\Wubi UninstallString D:\ubuntu\uninstall-wubi.exe 03-29 20:19 DEBUG registry: Setting registry key -2147483646 Software\Microsoft\Windows\CurrentVersion\Uninstall\Wubi InstallationDir D:\ubuntu 03-29 20:19 DEBUG registry: Setting registry key -2147483646 Software\Microsoft\Windows\CurrentVersion\Uninstall\Wubi DisplayName Ubuntu 03-29 20:19 DEBUG registry: Setting registry key -2147483646 Software\Microsoft\Windows\CurrentVersion\Uninstall\Wubi DisplayIcon D:\ubuntu\Ubuntu.ico 03-29 20:19 DEBUG registry: Setting registry key -2147483646 Software\Microsoft\Windows\CurrentVersion\Uninstall\Wubi DisplayVersion 11.10-rev241 03-29 20:19 DEBUG registry: Setting registry key -2147483646 Software\Microsoft\Windows\CurrentVersion\Uninstall\Wubi Publisher Ubuntu 03-29 20:19 DEBUG registry: Setting registry key -2147483646 Software\Microsoft\Windows\CurrentVersion\Uninstall\Wubi URLInfoAbout http://www.ubuntu.com 03-29 20:19 DEBUG registry: Setting registry key -2147483646 Software\Microsoft\Windows\CurrentVersion\Uninstall\Wubi HelpLink http://www.ubuntu.com/support 03-29 20:19 DEBUG TaskList: ## Finished create_uninstaller 03-29 20:19 DEBUG TaskList: ## Running copy_installation_files... 03-29 20:19 DEBUG WindowsBackend: Copying C:\Users\Home\AppData\Local\Temp\pylB911.tmp\data\custom-installation -> D:\ubuntu\install\custom-installation 03-29 20:19 DEBUG WindowsBackend: Copying C:\Users\Home\AppData\Local\Temp\pylB911.tmp\winboot -> D:\ubuntu\winboot 03-29 20:19 DEBUG WindowsBackend: Copying C:\Users\Home\AppData\Local\Temp\pylB911.tmp\data\images\Ubuntu.ico -> D:\ubuntu\Ubuntu.ico 03-29 20:19 DEBUG TaskList: ## Finished copy_installation_files 03-29 20:19 DEBUG TaskList: ## Running get_iso... 03-29 20:19 DEBUG TaskList: New task copy_file 03-29 20:19 DEBUG TaskList: ### Running copy_file... 03-29 20:23 ERROR TaskList: [Errno 13] Permission denied Traceback (most recent call last): File "\lib\wubi\backends\common\tasklist.py", line 197, in __call__ File "\lib\wubi\backends\common\utils.py", line 202, in copy_file IOError: [Errno 13] Permission denied 03-29 20:23 DEBUG TaskList: # Cancelling tasklist 03-29 20:23 DEBUG TaskList: New task check_iso 03-29 20:23 ERROR root: [Errno 13] Permission denied Traceback (most recent call last): File "\lib\wubi\application.py", line 58, in run File "\lib\wubi\application.py", line 130, in select_task File "\lib\wubi\application.py", line 205, in run_cd_menu File "\lib\wubi\application.py", line 120, in select_task File "\lib\wubi\application.py", line 158, in run_installer File "\lib\wubi\backends\common\tasklist.py", line 197, in __call__ File "\lib\wubi\backends\common\utils.py", line 202, in copy_file IOError: [Errno 13] Permission denied 03-29 20:23 ERROR TaskList: 'WindowsBackend' object has no attribute 'iso_path' Traceback (most recent call last): File "\lib\wubi\backends\common\tasklist.py", line 197, in __call__ File "\lib\wubi\backends\common\backend.py", line 579, in get_iso File "\lib\wubi\backends\common\backend.py", line 565, in use_iso AttributeError: 'WindowsBackend' object has no attribute 'iso_path' 03-29 20:23 DEBUG TaskList: # Cancelling tasklist 03-29 20:23 DEBUG TaskList: # Finished tasklist 03-29 20:29 INFO root: === wubi 11.10 rev241 === 03-29 20:29 DEBUG root: Logfile is c:\users\home\appdata\local\temp\wubi-11.10-rev241.log 03-29 20:29 DEBUG root: sys.argv = ['main.pyo', '--exefile="E:\\wubi.exe"'] 03-29 20:29 DEBUG CommonBackend: data_dir=C:\Users\Home\AppData\Local\Temp\pyl3487.tmp\data 03-29 20:29 DEBUG WindowsBackend: 7z=C:\Users\Home\AppData\Local\Temp\pyl3487.tmp\bin\7z.exe 03-29 20:29 DEBUG WindowsBackend: startup_folder=C:\ProgramData\Microsoft\Windows\Start Menu\Programs\Startup 03-29 20:29 DEBUG CommonBackend: Fetching basic info... 03-29 20:29 DEBUG CommonBackend: original_exe=E:\wubi.exe 03-29 20:29 DEBUG CommonBackend: platform=win32 03-29 20:29 DEBUG CommonBackend: osname=nt 03-29 20:29 DEBUG CommonBackend: language=en_IN 03-29 20:29 DEBUG CommonBackend: encoding=cp1252 03-29 20:29 DEBUG WindowsBackend: arch=amd64 03-29 20:29 DEBUG CommonBackend: Parsing isolist=C:\Users\Home\AppData\Local\Temp\pyl3487.tmp\data\isolist.ini 03-29 20:29 DEBUG CommonBackend: Adding distro Xubuntu-i386 03-29 20:29 DEBUG CommonBackend: Adding distro Xubuntu-amd64 03-29 20:29 DEBUG CommonBackend: Adding distro Kubuntu-amd64 03-29 20:29 DEBUG CommonBackend: Adding distro Mythbuntu-i386 03-29 20:29 DEBUG CommonBackend: Adding distro Ubuntu-amd64 03-29 20:29 DEBUG CommonBackend: Adding distro Ubuntu-i386 03-29 20:29 DEBUG CommonBackend: Adding distro Mythbuntu-amd64 03-29 20:29 DEBUG CommonBackend: Adding distro Kubuntu-i386 03-29 20:29 DEBUG WindowsBackend: Fetching host info... 03-29 20:29 DEBUG WindowsBackend: registry_key=Software\Microsoft\Windows\CurrentVersion\Uninstall\Wubi 03-29 20:29 DEBUG WindowsBackend: windows version=vista 03-29 20:29 DEBUG WindowsBackend: windows_version2=Windows 7 Home Basic 03-29 20:29 DEBUG WindowsBackend: windows_sp=None 03-29 20:29 DEBUG WindowsBackend: windows_build=7601 03-29 20:29 DEBUG WindowsBackend: gmt=5 03-29 20:29 DEBUG WindowsBackend: country=IN 03-29 20:29 DEBUG WindowsBackend: timezone=Asia/Calcutta 03-29 20:29 DEBUG WindowsBackend: windows_username=Home 03-29 20:29 DEBUG WindowsBackend: user_full_name=Home 03-29 20:29 DEBUG WindowsBackend: user_directory=C:\Users\Home 03-29 20:29 DEBUG WindowsBackend: windows_language_code=1033 03-29 20:29 DEBUG WindowsBackend: windows_language=English 03-29 20:29 DEBUG WindowsBackend: processor_name=Intel(R) Core(TM) i3 CPU M 370 @ 2.40GHz 03-29 20:29 DEBUG WindowsBackend: bootloader=vista 03-29 20:29 DEBUG WindowsBackend: system_drive=Drive(C: hd 61135.1523438 mb free ntfs) 03-29 20:29 DEBUG WindowsBackend: drive=Drive(C: hd 61135.1523438 mb free ntfs) 03-29 20:29 DEBUG WindowsBackend: drive=Drive(D: hd 12742.5507813 mb free ntfs) 03-29 20:29 DEBUG WindowsBackend: drive=Drive(E: cd 0.0 mb free cdfs) 03-29 20:29 DEBUG WindowsBackend: drive=Drive(F: cd 0.0 mb free ) 03-29 20:29 DEBUG WindowsBackend: drive=Drive(G: hd 93.22265625 mb free fat32) 03-29 20:29 DEBUG WindowsBackend: drive=Drive(Q: hd 0.0 mb free ) 03-29 20:29 DEBUG WindowsBackend: uninstaller_path=D:\ubuntu\uninstall-wubi.exe 03-29 20:29 DEBUG WindowsBackend: previous_target_dir=D:\ubuntu 03-29 20:29 DEBUG WindowsBackend: previous_distro_name=Ubuntu 03-29 20:29 DEBUG WindowsBackend: keyboard_id=67699721 03-29 20:29 DEBUG WindowsBackend: keyboard_layout=us 03-29 20:29 DEBUG WindowsBackend: keyboard_variant= 03-29 20:29 DEBUG CommonBackend: python locale=('en_IN', 'cp1252') 03-29 20:29 DEBUG CommonBackend: locale=en_IN 03-29 20:29 DEBUG WindowsBackend: total_memory_mb=3893.859375 03-29 20:29 DEBUG CommonBackend: Searching ISOs on USB devices 03-29 20:29 DEBUG CommonBackend: Searching for local CDs 03-29 20:29 DEBUG Distro: checking whether C:\Users\Home\AppData\Local\Temp\pyl3487.tmp is a valid Ubuntu CD 03-29 20:29 DEBUG Distro: does not contain C:\Users\Home\AppData\Local\Temp\pyl3487.tmp\casper\filesystem.squashfs 03-29 20:29 DEBUG Distro: checking whether C:\Users\Home\AppData\Local\Temp\pyl3487.tmp is a valid Ubuntu CD 03-29 20:29 DEBUG Distro: does not contain C:\Users\Home\AppData\Local\Temp\pyl3487.tmp\casper\filesystem.squashfs 03-29 20:29 DEBUG Distro: checking whether C:\Users\Home\AppData\Local\Temp\pyl3487.tmp is a valid Kubuntu CD 03-29 20:29 DEBUG Distro: does not contain C:\Users\Home\AppData\Local\Temp\pyl3487.tmp\casper\filesystem.squashfs 03-29 20:29 DEBUG Distro: checking whether C:\Users\Home\AppData\Local\Temp\pyl3487.tmp is a valid Kubuntu CD 03-29 20:29 DEBUG Distro: does not contain C:\Users\Home\AppData\Local\Temp\pyl3487.tmp\casper\filesystem.squashfs 03-29 20:29 DEBUG Distro: checking whether C:\Users\Home\AppData\Local\Temp\pyl3487.tmp is a valid Xubuntu CD 03-29 20:29 DEBUG Distro: does not contain C:\Users\Home\AppData\Local\Temp\pyl3487.tmp\casper\filesystem.squashfs 03-29 20:29 DEBUG Distro: checking whether C:\Users\Home\AppData\Local\Temp\pyl3487.tmp is a valid Xubuntu CD 03-29 20:29 DEBUG Distro: does not contain C:\Users\Home\AppData\Local\Temp\pyl3487.tmp\casper\filesystem.squashfs 03-29 20:29 DEBUG Distro: checking whether C:\Users\Home\AppData\Local\Temp\pyl3487.tmp is a valid Mythbuntu CD 03-29 20:29 DEBUG Distro: does not contain C:\Users\Home\AppData\Local\Temp\pyl3487.tmp\casper\filesystem.squashfs 03-29 20:29 DEBUG Distro: checking whether C:\Users\Home\AppData\Local\Temp\pyl3487.tmp is a valid Mythbuntu CD 03-29 20:29 DEBUG Distro: does not contain C:\Users\Home\AppData\Local\Temp\pyl3487.tmp\casper\filesystem.squashfs 03-29 20:29 DEBUG Distro: checking whether D:\ is a valid Ubuntu CD 03-29 20:29 DEBUG Distro: does not contain D:\casper\filesystem.squashfs 03-29 20:29 DEBUG Distro: checking whether D:\ is a valid Ubuntu CD 03-29 20:29 DEBUG Distro: does not contain D:\casper\filesystem.squashfs 03-29 20:29 DEBUG Distro: checking whether D:\ is a valid Kubuntu CD 03-29 20:29 DEBUG Distro: does not contain D:\casper\filesystem.squashfs 03-29 20:29 DEBUG Distro: checking whether D:\ is a valid Kubuntu CD 03-29 20:29 DEBUG Distro: does not contain D:\casper\filesystem.squashfs 03-29 20:29 DEBUG Distro: checking whether D:\ is a valid Xubuntu CD 03-29 20:29 DEBUG Distro: does not contain D:\casper\filesystem.squashfs 03-29 20:29 DEBUG Distro: checking whether D:\ is a valid Xubuntu CD 03-29 20:29 DEBUG Distro: does not contain D:\casper\filesystem.squashfs 03-29 20:29 DEBUG Distro: checking whether D:\ is a valid Mythbuntu CD 03-29 20:29 DEBUG Distro: does not contain D:\casper\filesystem.squashfs 03-29 20:29 DEBUG Distro: checking whether D:\ is a valid Mythbuntu CD 03-29 20:29 DEBUG Distro: does not contain D:\casper\filesystem.squashfs 03-29 20:29 DEBUG Distro: checking whether E:\ is a valid Ubuntu CD 03-29 20:29 DEBUG Distro: parsing info from str=Ubuntu 11.10 "Oneiric Ocelot" - Release i386 (20111012) 03-29 20:29 DEBUG Distro: parsed info={'name': 'Ubuntu', 'subversion': 'Release', 'version': '11.10', 'build': '20111012', 'codename': 'Oneiric Ocelot', 'arch': 'i386'} 03-29 20:29 INFO Distro: Found a valid CD for Ubuntu: E:\ 03-29 20:29 INFO root: Running the CD menu... 03-29 20:29 DEBUG WindowsFrontend: __init__... 03-29 20:29 DEBUG WindowsFrontend: on_init... 03-29 20:29 INFO WinuiPage: appname=wubi, localedir=C:\Users\Home\AppData\Local\Temp\pyl3487.tmp\translations, languages=['en_IN', 'en'] 03-29 20:29 INFO WinuiPage: appname=wubi, localedir=C:\Users\Home\AppData\Local\Temp\pyl3487.tmp\translations, languages=['en_IN', 'en'] 03-29 20:29 INFO root: CD menu finished 03-29 20:29 INFO root: Already installed, running the uninstaller... 03-29 20:29 INFO root: Running the uninstaller... 03-29 20:29 INFO CommonBackend: This is the uninstaller running 03-29 20:29 INFO WinuiPage: appname=wubi, localedir=C:\Users\Home\AppData\Local\Temp\pyl3487.tmp\translations, languages=['en_IN', 'en'] 03-29 20:29 INFO root: Received settings 03-29 20:29 INFO WinuiPage: appname=wubi, localedir=C:\Users\Home\AppData\Local\Temp\pyl3487.tmp\translations, languages=['en_IN', 'en'] 03-29 20:29 DEBUG TaskList: # Running tasklist... 03-29 20:29 DEBUG TaskList: ## Running Remove bootloader entry... 03-29 20:29 DEBUG WindowsBackend: Could not find bcd id 03-29 20:29 DEBUG WindowsBackend: undo_bootini C: 03-29 20:29 DEBUG WindowsBackend: undo_configsys Drive(C: hd 61135.1523438 mb free ntfs) 03-29 20:29 DEBUG WindowsBackend: undo_bootini D: 03-29 20:29 DEBUG WindowsBackend: undo_configsys Drive(D: hd 12742.5507813 mb free ntfs) 03-29 20:29 DEBUG WindowsBackend: undo_bootini G: 03-29 20:29 DEBUG WindowsBackend: undo_configsys Drive(G: hd 93.22265625 mb free fat32) 03-29 20:29 DEBUG WindowsBackend: undo_bootini Q: 03-29 20:29 DEBUG WindowsBackend: undo_configsys Drive(Q: hd 0.0 mb free ) 03-29 20:29 DEBUG TaskList: ## Finished Remove bootloader entry 03-29 20:29 DEBUG TaskList: ## Running Remove target dir... 03-29 20:29 DEBUG CommonBackend: Deleting D:\ubuntu 03-29 20:29 DEBUG TaskList: ## Finished Remove target dir 03-29 20:29 DEBUG TaskList: ## Running Remove registry key... 03-29 20:29 DEBUG TaskList: ## Finished Remove registry key 03-29 20:29 DEBUG TaskList: # Finished tasklist 03-29 20:29 INFO root: Almost finished uninstalling 03-29 20:29 INFO root: Finished uninstallation 03-29 20:29 DEBUG CommonBackend: Fetching basic info... 03-29 20:29 DEBUG CommonBackend: original_exe=E:\wubi.exe 03-29 20:29 DEBUG CommonBackend: platform=win32 03-29 20:29 DEBUG CommonBackend: osname=nt 03-29 20:29 DEBUG WindowsBackend: arch=amd64 03-29 20:29 DEBUG CommonBackend: Parsing isolist=C:\Users\Home\AppData\Local\Temp\pyl3487.tmp\data\isolist.ini 03-29 20:29 DEBUG CommonBackend: Adding distro Xubuntu-i386 03-29 20:29 DEBUG CommonBackend: Adding distro Xubuntu-amd64 03-29 20:29 DEBUG CommonBackend: Adding distro Kubuntu-amd64 03-29 20:29 DEBUG CommonBackend: Adding distro Mythbuntu-i386 03-29 20:29 DEBUG CommonBackend: Adding distro Ubuntu-amd64 03-29 20:29 DEBUG CommonBackend: Adding distro Ubuntu-i386 03-29 20:29 DEBUG CommonBackend: Adding distro Mythbuntu-amd64 03-29 20:29 DEBUG CommonBackend: Adding distro Kubuntu-i386 03-29 20:29 DEBUG WindowsBackend: Fetching host info... 03-29 20:29 DEBUG WindowsBackend: registry_key=Software\Microsoft\Windows\CurrentVersion\Uninstall\Wubi 03-29 20:29 DEBUG WindowsBackend: windows version=vista 03-29 20:29 DEBUG WindowsBackend: windows_version2=Windows 7 Home Basic 03-29 20:29 DEBUG WindowsBackend: windows_sp=None 03-29 20:29 DEBUG WindowsBackend: windows_build=7601 03-29 20:29 DEBUG WindowsBackend: gmt=5 03-29 20:29 DEBUG WindowsBackend: country=IN 03-29 20:29 DEBUG WindowsBackend: timezone=Asia/Calcutta 03-29 20:29 DEBUG WindowsBackend: windows_username=Home 03-29 20:29 DEBUG WindowsBackend: user_full_name=Home 03-29 20:29 DEBUG WindowsBackend: user_directory=C:\Users\Home 03-29 20:29 DEBUG WindowsBackend: windows_language_code=1033 03-29 20:29 DEBUG WindowsBackend: windows_language=English 03-29 20:29 DEBUG WindowsBackend: processor_name=Intel(R) Core(TM) i3 CPU M 370 @ 2.40GHz 03-29 20:29 DEBUG WindowsBackend: bootloader=vista 03-29 20:29 DEBUG WindowsBackend: system_drive=Drive(C: hd 61134.8632813 mb free ntfs) 03-29 20:29 DEBUG WindowsBackend: drive=Drive(C: hd 61134.8632813 mb free ntfs) 03-29 20:29 DEBUG WindowsBackend: drive=Drive(D: hd 12953.140625 mb free ntfs) 03-29 20:29 DEBUG WindowsBackend: drive=Drive(E: cd 0.0 mb free cdfs) 03-29 20:29 DEBUG WindowsBackend: drive=Drive(F: cd 0.0 mb free ) 03-29 20:29 DEBUG WindowsBackend: drive=Drive(G: hd 93.22265625 mb free fat32) 03-29 20:29 DEBUG WindowsBackend: drive=Drive(Q: hd 0.0 mb free ) 03-29 20:29 DEBUG WindowsBackend: uninstaller_path=None 03-29 20:29 DEBUG WindowsBackend: previous_target_dir=None 03-29 20:29 DEBUG WindowsBackend: previous_distro_name=None 03-29 20:29 DEBUG WindowsBackend: keyboard_id=67699721 03-29 20:29 DEBUG WindowsBackend: keyboard_layout=us 03-29 20:29 DEBUG WindowsBackend: keyboard_variant= 03-29 20:29 DEBUG WindowsBackend: total_memory_mb=3893.859375 03-29 20:29 DEBUG CommonBackend: Searching ISOs on USB devices 03-29 20:29 DEBUG CommonBackend: Searching for local CDs 03-29 20:29 DEBUG Distro: checking whether C:\Users\Home\AppData\Local\Temp\pyl3487.tmp is a valid Ubuntu CD 03-29 20:29 DEBUG Distro: does not contain C:\Users\Home\AppData\Local\Temp\pyl3487.tmp\casper\filesystem.squashfs 03-29 20:29 DEBUG Distro: checking whether C:\Users\Home\AppData\Local\Temp\pyl3487.tmp is a valid Ubuntu CD 03-29 20:29 DEBUG Distro: does not contain C:\Users\Home\AppData\Local\Temp\pyl3487.tmp\casper\filesystem.squashfs 03-29 20:29 DEBUG Distro: checking whether C:\Users\Home\AppData\Local\Temp\pyl3487.tmp is a valid Kubuntu CD 03-29 20:29 DEBUG Distro: does not contain C:\Users\Home\AppData\Local\Temp\pyl3487.tmp\casper\filesystem.squashfs 03-29 20:29 DEBUG Distro: checking whether C:\Users\Home\AppData\Local\Temp\pyl3487.tmp is a valid Kubuntu CD 03-29 20:29 DEBUG Distro: does not contain C:\Users\Home\AppData\Local\Temp\pyl3487.tmp\casper\filesystem.squashfs 03-29 20:29 DEBUG Distro: checking whether C:\Users\Home\AppData\Local\Temp\pyl3487.tmp is a valid Xubuntu CD 03-29 20:29 DEBUG Distro: does not contain C:\Users\Home\AppData\Local\Temp\pyl3487.tmp\casper\filesystem.squashfs 03-29 20:29 DEBUG Distro: checking whether C:\Users\Home\AppData\Local\Temp\pyl3487.tmp is a valid Xubuntu CD 03-29 20:29 DEBUG Distro: does not contain C:\Users\Home\AppData\Local\Temp\pyl3487.tmp\casper\filesystem.squashfs 03-29 20:29 DEBUG Distro: checking whether C:\Users\Home\AppData\Local\Temp\pyl3487.tmp is a valid Mythbuntu CD 03-29 20:29 DEBUG Distro: does not contain C:\Users\Home\AppData\Local\Temp\pyl3487.tmp\casper\filesystem.squashfs 03-29 20:29 DEBUG Distro: checking whether C:\Users\Home\AppData\Local\Temp\pyl3487.tmp is a valid Mythbuntu CD 03-29 20:29 DEBUG Distro: does not contain C:\Users\Home\AppData\Local\Temp\pyl3487.tmp\casper\filesystem.squashfs 03-29 20:29 DEBUG Distro: checking whether D:\ is a valid Ubuntu CD 03-29 20:29 DEBUG Distro: does not contain D:\casper\filesystem.squashfs 03-29 20:29 DEBUG Distro: checking whether D:\ is a valid Ubuntu CD 03-29 20:29 DEBUG Distro: does not contain D:\casper\filesystem.squashfs 03-29 20:29 DEBUG Distro: checking whether D:\ is a valid Kubuntu CD 03-29 20:29 DEBUG Distro: does not contain D:\casper\filesystem.squashfs 03-29 20:29 DEBUG Distro: checking whether D:\ is a valid Kubuntu CD 03-29 20:29 DEBUG Distro: does not contain D:\casper\filesystem.squashfs 03-29 20:29 DEBUG Distro: checking whether D:\ is a valid Xubuntu CD 03-29 20:29 DEBUG Distro: does not contain D:\casper\filesystem.squashfs 03-29 20:29 DEBUG Distro: checking whether D:\ is a valid Xubuntu CD 03-29 20:29 DEBUG Distro: does not contain D:\casper\filesystem.squashfs 03-29 20:29 DEBUG Distro: checking whether D:\ is a valid Mythbuntu CD 03-29 20:29 DEBUG Distro: does not contain D:\casper\filesystem.squashfs 03-29 20:29 DEBUG Distro: checking whether D:\ is a valid Mythbuntu CD 03-29 20:29 DEBUG Distro: does not contain D:\casper\filesystem.squashfs 03-29 20:29 DEBUG Distro: checking whether E:\ is a valid Ubuntu CD 03-29 20:29 INFO Distro: Found a valid CD for Ubuntu: E:\ 03-29 20:29 INFO root: Running the installer... 03-29 20:29 INFO WinuiPage: appname=wubi, localedir=C:\Users\Home\AppData\Local\Temp\pyl3487.tmp\translations, languages=['en_IN', 'en'] 03-29 20:29 INFO WinuiPage: appname=wubi, localedir=C:\Users\Home\AppData\Local\Temp\pyl3487.tmp\translations, languages=['en_IN', 'en'] 03-29 20:30 DEBUG WinuiInstallationPage: target_drive=C:, installation_size=8000MB, distro_name=Ubuntu, language=en_US, locale=en_US.UTF-8, username=taksh 03-29 20:30 INFO root: Received settings 03-29 20:30 INFO WinuiPage: appname=wubi, localedir=C:\Users\Home\AppData\Local\Temp\pyl3487.tmp\translations, languages=['en_US', 'en'] 03-29 20:30 DEBUG TaskList: # Running tasklist... 03-29 20:30 DEBUG TaskList: ## Running select_target_dir... 03-29 20:30 INFO WindowsBackend: Installing into C:\ubuntu 03-29 20:30 DEBUG TaskList: ## Finished select_target_dir 03-29 20:30 DEBUG TaskList: ## Running create_dir_structure... 03-29 20:30 DEBUG CommonBackend: Creating dir C:\ubuntu 03-29 20:30 DEBUG CommonBackend: Creating dir C:\ubuntu\disks 03-29 20:30 DEBUG CommonBackend: Creating dir C:\ubuntu\install 03-29 20:30 DEBUG CommonBackend: Creating dir C:\ubuntu\install\boot 03-29 20:30 DEBUG CommonBackend: Creating dir C:\ubuntu\disks\boot 03-29 20:30 DEBUG CommonBackend: Creating dir C:\ubuntu\disks\boot\grub 03-29 20:30 DEBUG CommonBackend: Creating dir C:\ubuntu\install\boot\grub 03-29 20:30 DEBUG TaskList: ## Finished create_dir_structure 03-29 20:30 DEBUG TaskList: ## Running uncompress_target_dir... 03-29 20:30 DEBUG TaskList: ## Finished uncompress_target_dir 03-29 20:30 DEBUG TaskList: ## Running create_uninstaller... 03-29 20:30 DEBUG WindowsBackend: Copying uninstaller E:\wubi.exe -> C:\ubuntu\uninstall-wubi.exe 03-29 20:30 DEBUG registry: Setting registry key -2147483646 Software\Microsoft\Windows\CurrentVersion\Uninstall\Wubi UninstallString C:\ubuntu\uninstall-wubi.exe 03-29 20:30 DEBUG registry: Setting registry key -2147483646 Software\Microsoft\Windows\CurrentVersion\Uninstall\Wubi InstallationDir C:\ubuntu 03-29 20:30 DEBUG registry: Setting registry key -2147483646 Software\Microsoft\Windows\CurrentVersion\Uninstall\Wubi DisplayName Ubuntu 03-29 20:30 DEBUG registry: Setting registry key -2147483646 Software\Microsoft\Windows\CurrentVersion\Uninstall\Wubi DisplayIcon C:\ubuntu\Ubuntu.ico 03-29 20:30 DEBUG registry: Setting registry key -2147483646 Software\Microsoft\Windows\CurrentVersion\Uninstall\Wubi DisplayVersion 11.10-rev241 03-29 20:30 DEBUG registry: Setting registry key -2147483646 Software\Microsoft\Windows\CurrentVersion\Uninstall\Wubi Publisher Ubuntu 03-29 20:30 DEBUG registry: Setting registry key -2147483646 Software\Microsoft\Windows\CurrentVersion\Uninstall\Wubi URLInfoAbout http://www.ubuntu.com 03-29 20:30 DEBUG registry: Setting registry key -2147483646 Software\Microsoft\Windows\CurrentVersion\Uninstall\Wubi HelpLink http://www.ubuntu.com/support 03-29 20:30 DEBUG TaskList: ## Finished create_uninstaller 03-29 20:30 DEBUG TaskList: ## Running copy_installation_files... 03-29 20:30 DEBUG WindowsBackend: Copying C:\Users\Home\AppData\Local\Temp\pyl3487.tmp\data\custom-installation -> C:\ubuntu\install\custom-installation 03-29 20:30 DEBUG WindowsBackend: Copying C:\Users\Home\AppData\Local\Temp\pyl3487.tmp\winboot -> C:\ubuntu\winboot 03-29 20:30 DEBUG WindowsBackend: Copying C:\Users\Home\AppData\Local\Temp\pyl3487.tmp\data\images\Ubuntu.ico -> C:\ubuntu\Ubuntu.ico 03-29 20:30 DEBUG TaskList: ## Finished copy_installation_files 03-29 20:30 DEBUG TaskList: ## Running get_iso... 03-29 20:30 DEBUG TaskList: New task copy_file 03-29 20:30 DEBUG TaskList: ### Running copy_file... 03-29 20:34 ERROR TaskList: [Errno 13] Permission denied Traceback (most recent call last): File "\lib\wubi\backends\common\tasklist.py", line 197, in __call__ File "\lib\wubi\backends\common\utils.py", line 202, in copy_file IOError: [Errno 13] Permission denied 03-29 20:34 DEBUG TaskList: # Cancelling tasklist 03-29 20:34 DEBUG TaskList: New task check_iso 03-29 20:34 ERROR root: [Errno 13] Permission denied Traceback (most recent call last): File "\lib\wubi\application.py", line 58, in run File "\lib\wubi\application.py", line 130, in select_task File "\lib\wubi\application.py", line 205, in run_cd_menu File "\lib\wubi\application.py", line 120, in select_task File "\lib\wubi\application.py", line 158, in run_installer File "\lib\wubi\backends\common\tasklist.py", line 197, in __call__ File "\lib\wubi\backends\common\utils.py", line 202, in copy_file IOError: [Errno 13] Permission denied 03-29 20:34 ERROR TaskList: 'WindowsBackend' object has no attribute 'iso_path' Traceback (most recent call last): File "\lib\wubi\backends\common\tasklist.py", line 197, in __call__ File "\lib\wubi\backends\common\backend.py", line 579, in get_iso File "\lib\wubi\backends\common\backend.py", line 565, in use_iso AttributeError: 'WindowsBackend' object has no attribute 'iso_path' 03-29 20:34 DEBUG TaskList: # Cancelling tasklist 03-29 20:34 DEBUG TaskList: # Finished tasklist I have no idea what's the problem is. I'm a kind of newbie. I'm using win7 64bit, and installing as an administrator. Please help me out!

    Read the article

  • debugging finite state machine spell checker code

    - by Durell
    I need someone to debug the lines of c++ code I wrote below so it can run. It is intended to spell check the word "and" using state to state transition. include include using namespace std; string in_str; int n; void spell_check() { int i; FILE *in_file; while (!EOF(in_file)) { fscanf(in_str); n = strlen(in_str); start(in_str,n); } } void start() { char next_char; int i = 0; if (n == 0) { cout<<"This is an empty string"; exit();//do something here to terminate the program } else{ next_char = in_str[i]; if(next_char == 'a') { i++; if(i >= n) error(); else state_A(i); } else error(); } } void state_A(int i) { if(in_str[i] == 'n') { i++; if(i void state_AN(int i) { if(in_str[i] == 'd') { if(i == n-1) cout<<" Your keyword spelling is correct"; else cout<<"Wrong keyword spelling"; } } int main() { spell_check(); return 0; }

    Read the article

  • How to copy files from HDD to HDD with integrity checking

    - by RafaelM
    I am moving data from an almost dead HDD to an external USB drive using linux , because for some reason Windows cannot see the data. I want to copy a large amount of data over from the HDD to the USB drive with integrity checking. I thought about copying everything over and then checking with md5summer but this would take a reaally long time because its a lot of data and this is not a very powerful PC. What tool can use to do this on Linux?

    Read the article

  • Vim is spellchecking in XML files where I don't want it to, and only there

    - by Kazark
    I'm trying to use Vim's builtin spellchecking in some XML documents. This happens merely by having the XML syntax loaded, as seen in the following minimalistic example (which reproduces what I also see in large XML documents): Note that given two buffers with exactly the same content, when Filetype is text, the spellchecking works; when it is xml, it does not. spell is set in both buffers. However, given this view of the top three lines of a large XML document, you can see that the spellchecking is certainly on: but it is only checking attributes. The nuisance is that none of the things it is actually finding are mispelled, and it isn't finding any of the numerous misspellings in the document. I would like it at a minimum to find the spelling errors in the body of the document, and being able to turn off the checking on attributes would be a nice option. I've searched for @NoSpell in the xml.vim file, but that returns no hits.

    Read the article

  • Having an issue with overwriting an element of a file correctly (numeric)

    - by IngeniousHax
    This is an ATM style program, but currently it doesn't do exactly what I need it to do... I need to get the current balance, and when money is transferred from either checking or savings, it should add it to checking and subtract it from savings. which is does, but not correctly... Input example -=[ Funds Transfer ]=- -=[ Savings to Checking ]=- Account Name: nomadic Amount to transfer: $400 New Balance in Checking: $900 // original was 500 New Balance in Savings: $7.7068e+012 // this should now be 1100... Here is my code, it's a lot of code, but there are no errors, so throwing it into an IDE and compiling should be fairly quick for whoever would like to help. mainBankClass.h mainBankClass.h #ifndef MAINBANKCLASS_H #define MAINBANKCLASS_H #include <iostream> #include <fstream> #include <string> using namespace std; class Banking { protected: string checkAcctName, saveAcctName; // Name on the account int acctNumber[13]; // Account number float acctBalance, initSaveDeposit, initCheckDeposit, depAmt; // amount in account, and amount to deposit public: char getBalanceChoice(); // Get name on account for displaying relevant information char newAccountMenu(); // Create a new account and assign it a random account number void invalid(char *); // If an invalid option is chosen char menu(); // Print the main menu for the user. virtual float deposit(){ return 0; } // virtual function for deposits // virtual float withdrawal() = 0; // Virtual function for withdrawals void fatal(char *); // Handles fatal errors. Banking(); }; class Checking : public Banking { public: friend ostream operator<<(ostream &, Checking &); friend istream operator>>(istream &, Checking &); Checking operator <= (const Checking &) const; void newCheckingAccount(); void viewCheckingBalance(); void transferFromSaving(); float deposit() { return (acctBalance += depAmt); } }; class Saving : public Banking { public: friend ostream &operator<<(ostream &, Saving &); friend istream &operator>>(istream &, Saving &); Saving operator <= (const Saving &) const; void newSavingAccount(); void viewSavingBalance(); void transferFromChecking(); float deposit() { return (acctBalance += depAmt); } }; class checkAndSave : public Banking { public: void newCheckAndSave(); void viewBothBalances(); }; #endif bankAccount.cpp #include <iostream> #include <sstream> #include <string> #include <iomanip> #include <fstream> #include <time.h> #include "MainBankClass.h" /*****************************\ | BANKING CONSTRUCTOR | \*****************************/ Banking::Banking() { string acctName; // Name on the account acctNumber[13] = 0; // Account number acctBalance = 0; initCheckDeposit = 0; initSaveDeposit = 0; depAmt = 0; }; /********************************\ | The following code is to print the menu | | and recieve the users choice on what | | they want to do with the ATM | \********************************/ char Banking::menu() { char choice; system("cls"); cout << "\t\t -=[ Main Menu ]=- \n\n" << "\tA) Create New Account\n" << "\tB) View Account Balance\n" << "\tC) Transfer Funds From Checking To Savings\n" << "\tD) Transfer Funds From Savings To Checking\n" << "\tE) Exit\n" << "\n\n\tSelection: "; cin >> choice; cin.ignore(); choice = toupper(choice); while(!isalpha(choice)) { invalid("[!!] Invalid selection.\n[!!] Choose a valid option: "); cin >> choice; cin.ignore(); } return choice; } /*********************\ | Will read in account choic | | and display it for the user | \*********************/ char Banking::getBalanceChoice() { char choice; fstream saveFile("saving.dat", ios::in | ios::beg); system("cls"); cout << "\t\t -=[ View Account Balance ]=-\n\n"; cout << "A) View Checking Account\n" << "B) View Saving Account\n" << "C) View Checking \\ Saving Account\n" << endl; cout << "Choice: "; cin >> choice; choice = toupper(choice); if(!isalpha(choice)) fatal(" [!!] Invalid Choice"); return choice; } /***************************\ | Incase an invalid decision to made | | this throws the error message sent | | to it by the calling area | \***************************/ void Banking::invalid(char *msg) { cout << msg; } /*************************\ | Used if files can not be opened | | and exits with code 251: | | miscommunication with server | \*************************/ void Banking::fatal(char *msg) { cout << msg; exit(1); } /***************************\ | Create an account, either checking | | or savings, or both. | | Must should create a randomly | | generated account number that will | | correspond with each account. | \***************************/ /************************\ NOTE:: WILL BE UPDATED TO CONTAIN A PIN FOR ACCOUNT VERIFICATION *************************/ char Banking::newAccountMenu() { srand(time(NULL)); // Seed random generator with time initialized to NULL char acctChoice; // choice for the account type ofstream checkFile("checking.dat", ios::out | ios::app); // For saving checking accounts ofstream saveFile("saving.dat", ios::out | ios::app); // For saving savings accounts system("cls"); cout << "\t\t-=[ New Account Creation ]=-\n\n" << endl; cout << "A) Checking Account\n" << "B) Savings Account\n" << "C) Checking and Saving Account\n" << endl; cout << "New account type: "; cin >> acctChoice; acctChoice = toupper(acctChoice); cin.clear(); cin.sync(); return acctChoice; } /********************************************************************* ********************************************************************** CHECKING ACCOUNT CODE ********************************************************************** **********************************************************************/ // New Checking Account Creation void Checking::newCheckingAccount() { system("cls"); ofstream checkFile("checking.dat", ios::out | ios::app); // For saving checking accounts cout << "\t\t -=[ New Checking Account ]=- \n" << endl; cout << "Name of the main holder to be on the account: "; getline(cin, checkAcctName); cout << "Initial deposit amount: $"; cin >> initCheckDeposit; if(initCheckDeposit <= 0) { while(initCheckDeposit <= 0) { invalid("[!!] 0 or negative amount entered\nMaybe a typo?\n"); cout << "Deposit Amount: $"; cin >> initCheckDeposit; } } if(!checkFile) fatal("[!!] Fatal Error 251: Miscommunication with server\n"); checkFile << checkAcctName << endl; for(int j = 0; j < 13; j++) { acctNumber[j] = (rand() % 10); // Build a random checking account number checkFile << acctNumber[j]; } checkFile << endl; checkFile << initCheckDeposit << endl; checkFile.close(); } void Checking::viewCheckingBalance() { fstream checkFile("checking.dat", ios::in | ios::beg); string name; int i = 0; double balance = 0; system("cls"); cout << "\t\t -=[ View Checking Account ]=-\n\n" << endl; cout << "Account Name: "; cin.sync(); getline(cin, name); getline(checkFile, checkAcctName); while(name != checkAcctName && !checkFile.fail()) { i++; getline(checkFile, checkAcctName); } if(name == checkAcctName) { system("cls"); cout << "\t\t -=[ Checking Account Balance ]=-\n\n" << endl; cout << "Account Name: " << checkAcctName << "\n"; cout << "Account Number: "; for(int j = 0; j < 13; j++) { char input_number; stringstream converter; checkFile.get(input_number); converter << input_number; converter >> acctNumber[j]; cout << acctNumber[j]; } // if balance a problem, try the below commented out line // checkFile.ignore(numeric_limits<streamsize>::max(), '\n'); cout << endl; checkFile >> acctBalance; cout << "Balance: $" << fixed << showpoint << setprecision(2) << acctBalance << endl; } else fatal("[!!] Invalid Account\n"); checkFile.close(); getchar(); } void Checking::transferFromSaving() // Move funds FROM SAVINGS to CHECKING { system("cls"); string name; long checkPos = 0; long savePos = 0; float savingBalance = 0; string saveAcctName; int i = 0; cin.clear(); fstream saveFile("saving.dat", ios::in | ios::out | ios::beg); fstream checkFile("checking.dat", ios::in | ios::out | ios::beg); cout << "\t\t-=[ Funds Transfer ]=-" << endl; cout << "\t\t-=[ Savings to Checking ]=-" << endl; cout << "Account Name: "; cin.sync(); getline(cin, name); getline(checkFile, checkAcctName); while(name != checkAcctName && !checkFile.fail()) { i++; getline(checkFile, checkAcctName); } getline(saveFile, saveAcctName); while(name != saveAcctName && !saveFile.fail()) { i = 0; i++; getline(saveFile, saveAcctName); } if(name == checkAcctName) { cout << "Amount to transfer: $"; float depAmt = 0; cin >> depAmt; for(int j = 0; j < 13; j++) { char input_number; stringstream converter; checkFile.get(input_number); converter << input_number; converter >> acctNumber[j]; } checkPos = checkFile.tellg(); // if the file is found, get the position of acctBalance and store it in ptrPos checkFile.seekg(checkPos); checkFile >> acctBalance; savePos = saveFile.tellg(); saveFile.seekg(savePos); // sending the cursor in the file to ptrPos + 1 to ignore white space saveFile >> savingBalance; if(savingBalance < depAmt) // if checking account does not have enough funds, exit with NSF code fatal("[!!] Insufficient Funds\n"); acctBalance += depAmt; // can be changed to an overloaded operator savingBalance -= depAmt; // can be changed to an overloaded operator checkFile.seekp(checkPos); // go to position previously set above checkFile << acctBalance; // write new balance to checkFile saveFile.seekp(savePos); // same thing as above comment saveFile << savingBalance; // write new balance to saveFile cout << "New Balance in Checking: $" << acctBalance << endl; // will be removed later cout << "New Balance in Savings: $" << savingBalance << endl; // will be removed later aswell } else fatal("[!!] Linked accounts do not exist.\n"); // if account is not found saveFile.close(); checkFile.close(); } /******************************************************** ******************************************************** SAVING ACCOUNT CODE ********************************************************* *********************************************************/ void Saving::newSavingAccount() { system("cls"); ofstream saveFile("saving.dat", ios::out | ios::app); // For saving savings accounts cout << "\t\t -=[ New Savings Account ]=- \n" << endl; cout << "Name of the main holder to be on account: "; getline(cin, saveAcctName); cout << "Deposit Amount: $"; cin >> initSaveDeposit; if(initSaveDeposit <= 0) { while(initSaveDeposit <= 0) { invalid("[!!]0 or negative value entered.\nPerhaps a typo?\n"); cout << "Deposit amount: $"; cin >> initSaveDeposit; } } if(!saveFile) fatal("[!!] Fatal Error 251: Miscommunication with server\n"); saveFile << saveAcctName << endl; for(int j = 0; j < 13; j++) { acctNumber[j] = (rand() % 10); saveFile << acctNumber[j]; } saveFile << endl; saveFile << initSaveDeposit << endl; saveFile.close(); } void Saving::viewSavingBalance() { string name; int i = 0; fstream saveFile("saving.dat", ios::in | ios::beg); cin.clear(); system("cls"); cout << "\t\t -=[ View Saving Account ]=-\n\n" << endl; cout << "Account Name: "; cin.sync(); getline(cin, name); getline(saveFile, saveAcctName); while(name != saveAcctName && !saveFile.fail()) { i++; getline(saveFile, saveAcctName); } if(name == saveAcctName) { system("cls"); cout << "\t\t -=[ Saving Account Balance ]=-\n\n" << endl; cout << "Account Name: " << saveAcctName << "\n"; cout << "Account Number: "; for(int j = 0; j < 13; j++) { char input_number; stringstream converter; saveFile.get(input_number); converter << input_number; converter >> acctNumber[j]; cout << acctNumber[j]; } // if balance a problem, try the below commented out line // checkFile.ignore(numeric_limits<streamsize>::max(), '\n'); cout << endl; saveFile >> acctBalance; cout << "Balance: $" << fixed << showpoint << setprecision(2) << acctBalance << endl; } else fatal("[!!] Invalid Account\n"); saveFile.close(); getchar(); } // NEED TO WORK ON THIS PORTION TOMORROW AND MONDAY, ADD OVERLOADED OPS FOR ASSIGNMENT!!!!!!! void Saving::transferFromChecking() // This is to take money FROM checking and ADD IT TO SAVING { system("cls"); string name; long savePos = 0; long checkPos = 0; float checkingBalance = 0; string checkAcctName; int i = 0; cin.clear(); fstream saveFile("saving.dat", ios::in | ios::out | ios::beg); fstream checkFile("checking.dat", ios::in | ios::out | ios::beg); cout << "\t\t-=[ Funds Transfer ]=-" << endl; cout << "\t\t-=[ Checking to Savings ]=-" << endl; cout << "Account Name: "; cin.sync(); getline(cin, name); getline(saveFile, saveAcctName); getline(checkFile, checkAcctName); while(name != saveAcctName && name != checkAcctName && !saveFile.fail() && !checkFile.fail()) { i++; getline(saveFile, saveAcctName); getline(checkFile, checkAcctName); } if(name == saveAcctName) { cout << "Amount to transfer: $"; float depAmt = 0; cin >> depAmt; for(int j = 0; j < 13; j++) { char input_number; stringstream converter; saveFile.get(input_number); converter << input_number; converter >> acctNumber[j]; } savePos = saveFile.tellg(); // if the file is found, get the position of acctBalance and store it in ptrPos saveFile.seekg(savePos); saveFile >> acctBalance; checkPos = checkFile.tellg(); checkFile.seekg(checkPos); // if file is found, store current position of the cursor to ptrPos checkFile >> checkingBalance; if(checkingBalance < depAmt) // if checking account does not have enough funds, exit with NSF code fatal("[!!] Insufficient Funds\n"); // Can also place overloaded op here acctBalance += depAmt; // can be changed to an overloaded operator checkingBalance -= depAmt; // can be changed to an overloaded operator saveFile.seekg(savePos); // go to position previously set above saveFile << acctBalance; // write new balance to saveFile checkFile.seekg(checkPos); // same thing as above comment checkFile << checkingBalance; // write new balance to checkFile cout << "New Balance in Savings: $" << acctBalance << endl; // will be removed later cout << "New Balance in Checking: $" << checkingBalance << endl; // will be removed later aswell } else fatal("[!!] Linked accounts do not exist.\n"); // if account is not found saveFile.close(); checkFile.close(); } /******************************************** ******************************************** CHECK AND SAVE CODE ********************************************** **********************************************/ void checkAndSave::newCheckAndSave() { system("cls"); ofstream saveFile("saving.dat", ios::out | ios::app); // For saving savings accounts ofstream checkFile("checking.dat", ios::out | ios::app); // For saving checking accounts cout << "\t -=[ New Checking & Saving Account ]=- \n" << endl; cout << "Name of the main holder to be on account: "; getline(cin, checkAcctName); saveAcctName = checkAcctName; cout << "Checking Deposit Amount: $"; cin >> initCheckDeposit; if(initCheckDeposit <= 0) { while(initCheckDeposit <= 0) { invalid("[!!] 0 or negative amount entered\nMaybe a typo?\n"); cout << "Deposit Amount: $"; cin >> initCheckDeposit; } } cout << "Saving Deposit Amount: $"; cin >> initSaveDeposit; if(initSaveDeposit <= 0) { while(initSaveDeposit <= 0) { invalid("[!!]0 or negative value entered.\nPerhaps a typo?\n"); cout << "Deposit amount: $"; cin >> initSaveDeposit; } } if(!saveFile || !checkFile) fatal("[!!] Fatal Error 251: Miscommunication with server\n"); checkFile << checkAcctName << endl; saveFile << saveAcctName << endl; for(int j = 0; j < 13; j++) { acctNumber[j] = (rand() % 10); checkFile << acctNumber[j]; saveFile << acctNumber[j]; } saveFile << endl; saveFile << initSaveDeposit << endl; checkFile << endl; checkFile << initCheckDeposit << endl; checkFile.close(); saveFile.close(); } void checkAndSave::viewBothBalances() { string name; int i = 0; fstream checkFile("checking.dat", ios::in | ios::beg); fstream saveFile("saving.dat", ios::in | ios::beg); system("cls"); cin.clear(); cout << "\t-=[ Saving & Checking Account Balance ]=-\n\n" << endl; cout << "Account Name: "; cin.sync(); getline(cin, name); getline(checkFile, checkAcctName); saveAcctName = name; /**********************\ | Checking Account portion | | of the checking & savings | | overview | \**********************/ while(name != checkAcctName && !checkFile.fail()) { i++; getline(checkFile, checkAcctName); } system("cls"); if(name != checkAcctName && checkFile.fail()) invalid("\n\n[!!] No Checking Account Found\n"); cout << "\t\t -=[ Checking Account ]=- \n" << endl; cout << "Account Name: " << checkAcctName << "\n"; cout << "Account Number: "; for(int j = 0; j < 13; j++) { char input_number; stringstream converter; checkFile.get(input_number); converter << input_number; converter >> acctNumber[j]; cout << acctNumber[j]; } // if balance a problem, try the below commented out line // checkFile.ignore(numeric_limits<streamsize>::max(), '\n'); cout << endl; checkFile >> acctBalance; cout << "Balance: $" << fixed << showpoint << setprecision(2) << acctBalance << endl; /*********************\ | Saving Account portion | | of the checking & saving | | overview | \*********************/ getline(saveFile, saveAcctName); while(name != saveAcctName && !saveFile.fail()) { i++; getline(saveFile, saveAcctName); } if(name != saveAcctName && saveFile.fail()) invalid("\n\n[!!] No Saving Account Found\n"); if(name == saveAcctName) { cout << "\t\t -=[ Saving Account ]=-\n\n" << endl; cout << "Account Name: " << saveAcctName << "\n"; cout << "Account Number: "; for(int j = 0; j < 13; j++) { char input_number; stringstream converter; saveFile.get(input_number); converter << input_number; converter >> acctNumber[j]; cout << acctNumber[j]; } // if balance a problem, try the below commented out line // checkFile.ignore(numeric_limits<streamsize>::max(), '\n'); cout << endl; saveFile >> acctBalance; cout << "Balance: $" << fixed << showpoint << setprecision(2) << acctBalance << endl; } if(name != saveAcctName && name != checkAcctName && saveFile.fail() && checkFile.fail()) fatal("[!!] No Accounts Have Been Found\n"); checkFile.close(); saveFile.close(); getchar(); } Main.cpp #include <iostream> #include "MainBankClass.h" using namespace std; int main() { Banking bank; Checking check; Saving save; checkAndSave CanS; char choice; choice = bank.menu(); // Call the banking menu switch(choice) { case 'A': choice = bank.newAccountMenu(); switch(choice) { case 'A': check.newCheckingAccount(); break; case 'B': save.newSavingAccount(); break; case 'C': CanS.newCheckAndSave(); break; default: system("cls"); bank.fatal("[!!] Invalid option\n"); break; } break; /***********************************************/ case 'B': choice = bank.getBalanceChoice(); switch(choice) { case 'A': check.viewCheckingBalance(); break; case 'B': save.viewSavingBalance(); break; case 'C': CanS.viewBothBalances(); break; default: bank.fatal("Invalid decision\n"); break; } /*************************************************/ break; case 'C': check.transferFromSaving(); break; case 'D': save.transferFromChecking(); break; case 'E': system("cls"); cout << "\t\t-=[ Disconnecting From System ]=-\n"; cout << "\t\t\t Thank you" << endl; cout << "\t\t Have a nice day!" << endl; exit(1); break; default: system("cls"); bank.invalid("\n\n\n\n\t\t [+] Invalid Selection \n\t\t[+] Disconnecting From System \n\t\t\tGood-bye \n\n\n\n\n\n\n"); exit(1); break; } return 0; }

    Read the article

  • When is type testing OK?

    - by svidgen
    Assuming a language with some inherent type safety (e.g., not JavaScript): Given a method that accepts a SuperType, we know that in most cases wherein we might be tempted to perform type testing to pick an action: public void DoSomethingTo(SuperType o) { if (o isa SubTypeA) { o.doSomethingA() } else { o.doSomethingB(); } } We should usually, if not always, create a single, overridable method on the SuperType and do this: public void DoSomethingTo(SuperType o) { o.doSomething(); } ... wherein each subtype is given its own doSomething() implementation. The rest of our application can then be appropriately ignorant of whether any given SuperType is really a SubTypeA or a SubTypeB. Wonderful. But, we're still given is a-like operations in most, if not all, type-safe languages. And that seems suggests a potential need for explicit type testing. So, in what situations, if any, should we or must we perform explicit type testing? Forgive my absent mindedness or lack of creativity. I know I've done it before; but, it was honestly so long ago I can't remember if what I did was good! And in recent memory, I don't think I've encountered a need to test types outside my cowboy JavaScript.

    Read the article

  • Error when trying to compile abgx360: C++ compiler cannot create executables

    - by era878
    I am trying to compile the abgx360 GUI. First I run home/eric/Desktop/abgx360-1.0.5/configure but I recieve this error: checking for C++ compiler default output file name... configure: error: C++ compiler cannot create executables See `config.log' for more details. Then i run make but I recieve this error: make: * No rule to make target `/home/eric/Desktop/abgx360-1.0.5/Makefile.am', needed by `/home/eric/Desktop/abgx360-1.0.5/Makefile.in'. Stop. Here is my 'config.log': This file contains any messages produced by compilers while running configure, to aid debugging if configure makes a mistake. It was created by abgx360gui configure 1.0.2, which was generated by GNU Autoconf 2.61. Invocation command line was $ /home/eric/Desktop/abgx360gui-1.0.2/configure ## --------- ## ## Platform. ## ## --------- ## hostname = Eric-Desktop uname -m = x86_64 uname -r = 2.6.35-27-generic uname -s = Linux uname -v = #48-Ubuntu SMP Tue Feb 22 20:25:46 UTC 2011 /usr/bin/uname -p = unknown /bin/uname -X = unknown /bin/arch = unknown /usr/bin/arch -k = unknown /usr/convex/getsysinfo = unknown /usr/bin/hostinfo = unknown /bin/machine = unknown /usr/bin/oslevel = unknown /bin/universe = unknown PATH: /usr/local/sbin PATH: /usr/local/bin PATH: /usr/sbin PATH: /usr/bin PATH: /sbin PATH: /bin PATH: /usr/games ## ----------- ## ## Core tests. ## ## ----------- ## configure:1800: checking for a BSD-compatible install configure:1856: result: /usr/bin/install -c configure:1867: checking whether build environment is sane configure:1910: result: yes configure:1938: checking for a thread-safe mkdir -p configure:1977: result: /bin/mkdir -p configure:1990: checking for gawk configure:2020: result: no configure:1990: checking for mawk configure:2006: found /usr/bin/mawk configure:2017: result: mawk configure:2028: checking whether make sets $(MAKE) configure:2049: result: yes configure:2302: checking for g++ configure:2332: result: no configure:2302: checking for c++ configure:2332: result: no configure:2302: checking for gpp configure:2332: result: no configure:2302: checking for aCC configure:2332: result: no configure:2302: checking for CC configure:2332: result: no configure:2302: checking for cxx configure:2332: result: no configure:2302: checking for cc++ configure:2332: result: no configure:2302: checking for cl.exe configure:2332: result: no configure:2302: checking for FCC configure:2332: result: no configure:2302: checking for KCC configure:2332: result: no configure:2302: checking for RCC configure:2332: result: no configure:2302: checking for xlC_r configure:2332: result: no configure:2302: checking for xlC configure:2332: result: no configure:2360: checking for C++ compiler version configure:2367: g++ --version >&5 /home/eric/Desktop/abgx360gui-1.0.2/configure: line 2368: g++: command not found configure:2370: $? = 127 configure:2377: g++ -v >&5 /home/eric/Desktop/abgx360gui-1.0.2/configure: line 2378: g++: command not found configure:2380: $? = 127 configure:2387: g++ -V >&5 /home/eric/Desktop/abgx360gui-1.0.2/configure: line 2388: g++: command not found configure:2390: $? = 127 configure:2413: checking for C++ compiler default output file name configure:2440: g++ conftest.cpp >&5 /home/eric/Desktop/abgx360gui-1.0.2/configure: line 2441: g++: command not found configure:2443: $? = 127 configure:2481: result: configure: failed program was: | /* confdefs.h. */ | #define PACKAGE_NAME "abgx360gui" | #define PACKAGE_TARNAME "abgx360gui" | #define PACKAGE_VERSION "1.0.2" | #define PACKAGE_STRING "abgx360gui 1.0.2" | #define PACKAGE_BUGREPORT "" | #define PACKAGE "abgx360gui" | #define VERSION "1.0.2" | /* end confdefs.h. */ | | int | main () | { | | ; | return 0; | } configure:2488: error: C++ compiler cannot create executables See `config.log' for more details. ## ---------------- ## ## Cache variables. ## ## ---------------- ## ac_cv_env_CCC_set= ac_cv_env_CCC_value= ac_cv_env_CC_set= ac_cv_env_CC_value= ac_cv_env_CFLAGS_set= ac_cv_env_CFLAGS_value= ac_cv_env_CPPFLAGS_set= ac_cv_env_CPPFLAGS_value= ac_cv_env_CPP_set= ac_cv_env_CPP_value= ac_cv_env_CXXFLAGS_set= ac_cv_env_CXXFLAGS_value= ac_cv_env_CXX_set= ac_cv_env_CXX_value= ac_cv_env_LDFLAGS_set= ac_cv_env_LDFLAGS_value= ac_cv_env_LIBS_set= ac_cv_env_LIBS_value= ac_cv_env_build_alias_set= ac_cv_env_build_alias_value= ac_cv_env_host_alias_set= ac_cv_env_host_alias_value= ac_cv_env_target_alias_set= ac_cv_env_target_alias_value= ac_cv_path_install='/usr/bin/install -c' ac_cv_path_mkdir=/bin/mkdir ac_cv_prog_AWK=mawk ac_cv_prog_make_make_set=yes ## ----------------- ## ## Output variables. ## ## ----------------- ## ACLOCAL='${SHELL} /home/eric/Desktop/abgx360gui-1.0.2/missing --run aclocal-1.10' AMDEPBACKSLASH='' AMDEP_FALSE='' AMDEP_TRUE='' AMTAR='${SHELL} /home/eric/Desktop/abgx360gui-1.0.2/missing --run tar' AUTOCONF='${SHELL} /home/eric/Desktop/abgx360gui-1.0.2/missing --run autoconf' AUTOHEADER='${SHELL} /home/eric/Desktop/abgx360gui-1.0.2/missing --run autoheader' AUTOMAKE='${SHELL} /home/eric/Desktop/abgx360gui-1.0.2/missing --run automake-1.10' AWK='mawk' CC='' CCDEPMODE='' CFLAGS='' CPP='' CPPFLAGS='' CXX='g++' CXXDEPMODE='' CXXFLAGS='' CYGPATH_W='echo' DEFS='' DEPDIR='' ECHO_C='' ECHO_N='-n' ECHO_T='' EGREP='' EXEEXT='' GREP='' INSTALL_DATA='${INSTALL} -m 644' INSTALL_PROGRAM='${INSTALL}' INSTALL_SCRIPT='${INSTALL}' INSTALL_STRIP_PROGRAM='$(install_sh) -c -s' LDFLAGS='' LIBOBJS='' LIBS='' LTLIBOBJS='' MAKEINFO='${SHELL} /home/eric/Desktop/abgx360gui-1.0.2/missing --run makeinfo' OBJEXT='' PACKAGE='abgx360gui' PACKAGE_BUGREPORT='' PACKAGE_NAME='abgx360gui' PACKAGE_STRING='abgx360gui 1.0.2' PACKAGE_TARNAME='abgx360gui' PACKAGE_VERSION='1.0.2' PATH_SEPARATOR=':' SET_MAKE='' SHELL='/bin/bash' STRIP='' VERSION='1.0.2' WX_CFLAGS='' WX_CFLAGS_ONLY='' WX_CONFIG_PATH='' WX_CPPFLAGS='' WX_CXXFLAGS='' WX_CXXFLAGS_ONLY='' WX_LIBS='' WX_LIBS_STATIC='' WX_RESCOMP='' WX_VERSION='' ac_ct_CC='' ac_ct_CXX='' am__fastdepCC_FALSE='' am__fastdepCC_TRUE='' am__fastdepCXX_FALSE='' am__fastdepCXX_TRUE='' am__include='' am__isrc=' -I$(srcdir)' am__leading_dot='.' am__quote='' am__tar='${AMTAR} chof - "$$tardir"' am__untar='${AMTAR} xf -' bindir='${exec_prefix}/bin' build_alias='' datadir='${datarootdir}' datarootdir='${prefix}/share' docdir='${datarootdir}/doc/${PACKAGE_TARNAME}' dvidir='${docdir}' exec_prefix='NONE' host_alias='' htmldir='${docdir}' includedir='${prefix}/include' infodir='${datarootdir}/info' install_sh='$(SHELL) /home/eric/Desktop/abgx360gui-1.0.2/install-sh' libdir='${exec_prefix}/lib' libexecdir='${exec_prefix}/libexec' localedir='${datarootdir}/locale' localstatedir='${prefix}/var' mandir='${datarootdir}/man' mkdir_p='/bin/mkdir -p' oldincludedir='/usr/include' pdfdir='${docdir}' prefix='NONE' program_transform_name='s,x,x,' psdir='${docdir}' sbindir='${exec_prefix}/sbin' sharedstatedir='${prefix}/com' sysconfdir='${prefix}/etc' target_alias='' ## ----------- ## ## confdefs.h. ## ## ----------- ## #define PACKAGE_NAME "abgx360gui" #define PACKAGE_TARNAME "abgx360gui" #define PACKAGE_VERSION "1.0.2" #define PACKAGE_STRING "abgx360gui 1.0.2" #define PACKAGE_BUGREPORT "" #define PACKAGE "abgx360gui" #define VERSION "1.0.2" configure: exit 77

    Read the article

  • why i failed to configure openvpn, now i am an ordinary user, how to deal with this issue?

    - by hugemeow
    checking tap-windows.h presence... no checking for tap-windows.h... no checking whether TUNSETPERSIST is declared... yes checking for setcon in -lselinux... yes checking for pam_start in -lpam... no checking for OPENSSL_CRYPTO... yes checking for OPENSSL_SSL... yes checking for EVP_CIPHER_CTX_set_key_length... yes checking for ENGINE_load_builtin_engines... yes checking for ENGINE_register_all_complete... yes checking for ENGINE_cleanup... yes checking for ssl_init in -lpolarssl... no checking for aes_crypt_cbc in -lpolarssl... no checking for lzo1x_1_15_compress in -llzo2... no checking for lzo1x_1_15_compress in -llzo... no checking for PKCS11_HELPER... no checking git checkout... yes configure: error: libpam required but missing [mirror@innov openvpn]$ ./configure --help | grep libpam --enable-pam-dlopen dlopen libpam [default=no] C compiler flags for libpam LIBPAM_LIBS linker flags for libpam [mirror@xxx openvpn]$ ./configure --prefix=/home/mirror/build/ins/ins_vpn --disable-lzo error: libpam required but missing i just have no privilege to install the package named libpam, so can i build libpam and install it in home directory, then build openvpn based on it?

    Read the article

  • What is a good "Error Checking" Pattern (Java)?

    - by Jack
    I'll explain what I mean by input error checking. Say you have a function doSomething(x). If the function completes successfully doSomething does something and returns nothing. However, if there are errors I'd like to be notified. That is what I mean by error checking. I'm looking for, in general, the best way to check for errors. I've thought of the following solutions, each with a potential problem. Flag error checking. If doSomething(x) completes successfully return null. Otherwise, it returns a boolean or an error string. Problem: Side effects. Throwing an exception. Throw an exception if doSomething(x) encounters an error. Problem: If you are performing error checking for parameters only, throwing an IllegalArgumentExceptionseems inappropriate. Validating input prior to function call. If the error checking is only meant for the parameters of the function, then you can call a validator function before calling the doSomething(x) function. Problem: What if a client of the class forgets to call the validator function before calling doSomething(x)? I often encounter this problem and any help or a point in the right direction would be much appreciated.

    Read the article

  • MS Word custom dictionary making spellcheck slow - ideas?

    - by ezuk
    I have a user who edits technical materials. She uses MS Word's Custom Dictionary all the time for spelling; it has grown very large, and is now making spell check very slow. All of the advice I've read online says to disable the custom dictionary. This is an easy solution, but is not workable for the user, because she actually needs this dictionary. So, is there any way to optimize the custom dictionary and/or Word itself, so that a large dictionary file doesn't slow things down quite so badly? Many thanks. Update after suggestions: I ran contig on the file, and it reports just 1 frag, so that's not the issue I think. The file is 9.95KB -- 1,117 lines, each consisting of just a single word. I viewed the file using Notepad and none of the lines seems corrupted, strange, or overly long (no line seems to be over 10 chars or so). Both of your suggestions were helpful so I will upvote both; any further tips would be most welcome.

    Read the article

  • how to install 'version.h' in ubuntu ?

    - by user252098
    Just now , I try to install the Jungo WinDriver in the Ubuntu 13.10 . But I am puzzled by the its manual of how to Install version.h : Install version.h: The file version.h is created when you first compile the Linux kernel source code. Some distributions provide a compiled kernel without the file version.h. Look under /usr/src/linux/include/linux to see whether you have this file. If you do not, follow these steps: Become super user: $ su Change directory to the Linux source directory: # cd /usr/src/linux Type: # make xconfig Save the configuration by choosing Save and Exit. Type: # make dep Exit super user mode: # exit But the shell says: warning: make dep is unnecessary now. Then, I found out there is a version.h in /usr/src/linux-headers-3.11.0.12-generic, so I type: /usr/src/windriver/redist# ./configure --with-kernel-source=/usr/src/linux-headers-3.11.0.12-generic But, the windriver run fails: USE_KBUILD = yes checking for cpu architecture... x86_64 checking for WinDriver root directory... /usr/src/WinDriver checking for linux kernel source... found at /usr/src/linux checking for lib directory... ln -sf $(ROOT_DIR)/lib/$(SHARED_OBJECT)_32.so /usr/lib/$(SHARED_OBJECT).so; ln -s /usr/lib /usr/lib64; ln -sf $(ROOT_DIR)/lib/$(SHARED_OBJECT).so /usr/lib64/$(SHARED_OBJECT).so checking which directories to include... -I/usr/src/linux/include checking linux kernel version... 3.11.10.6 checking for modules installation directory... /lib/modules/3.11.0-12-generic/kernel/drivers/misc checking output directory... LINUX.3.11.0-12-generic.x86_64 checking target... LINUX.3.11.0-12-generic.x86_64/windrvr6_usb.ko checking for regparm kernel option... find: `/usr/src/WinDriver/redist/.tmp_driver/.tmp_versions': No such file or directory 0 checking for modpost location... /usr/src/linux/scripts/mod/modpost configure.usb: creating ./config.status config.status: creating makefile.usb.kbuild checking for cpu architecture... x86_64 checking for WinDriver root directory... /usr/src/WinDriver checking for linux kernel source... found at /usr/src/linux checking for lib directory... ln -sf $(ROOT_DIR)/lib/$(SHARED_OBJECT)_32.so /usr/lib/$(SHARED_OBJECT).so; ln -s /usr/lib /usr/lib64; ln -sf $(ROOT_DIR)/lib/$(SHARED_OBJECT).so /usr/lib64/$(SHARED_OBJECT).so checking which directories to include... -I/usr/src/linux/include checking linux kernel version... 3.11.10.6 checking for modules installation directory... /lib/modules/3.11.0-12-generic/kernel/drivers/misc checking output directory... LINUX.3.11.0-12-generic.x86_64 checking target... LINUX.3.11.0-12-generic.x86_64/windrvr6.ko checking for regparm kernel option... find: `/usr/src/WinDriver/redist/.tmp_driver/.tmp_versions': No such file or directory 0 checking for right linked object... windrvr_gcc_v3.a checking for modpost location... /usr/src/linux/scripts/mod/modpost configure.wd: creating ./config.status config.status: creating makefile.wd.kbuild What is the problem?

    Read the article

  • Spell Check in IE

    - by Prashant
    In Firefox, if a user enters words which have spelling mistakes, the browser puts a line below the word indicating a spelling mistake. How can the same be accomplished in IE ? Any ideas ?

    Read the article

  • NHunspell Spell

    - by mouthpiec
    Hi, Can someone explain the letters after the '/' mean? The example below show an extract of the dictionary accessory/SM access/SDMG accidence/M accidentalness/M accidental/SPY accident/MS acclaimer/M acclaim/SDRG acclamation/MS acclimate/XSDGN acclimation/M acclimatisation

    Read the article

  • Header Guard Issues - Getting Swallowed Alive

    - by gjnave
    I'm totally at wit's end: I can't figure out how my dependency issues. I've read countless posts and blogs and reworked my code so many times that I can't even remember what almost worked and what didnt. I continually get not only redefinition errors, but class not defined errors. I rework the header guards and remove some errors simply to find others. I somehow got everything down to one error but then even that got broke while trying to fix it. Would you please help me figure out the problem? card.cpp #include <iostream> #include <cctype> #include "card.h" using namespace std; // ====DECL====== Card::Card() { abilities = 0; flavorText = 0; keywords = 0; artifact = 0; classType = new char[strlen("Card") + 1]; classType = "Card"; } Card::~Card (){ delete name; delete abilities; delete flavorText; artifact = NULL; } // ------------ Card::Card(const Card & to_copy) { name = new char[strlen(to_copy.name) +1]; // creating dynamic array strcpy(to_copy.name, name); type = to_copy.type; color = to_copy.color; manaCost = to_copy.manaCost; abilities = new char[strlen(to_copy.abilities) +1]; strcpy(abilities, to_copy.abilities); flavorText = new char[strlen(to_copy.flavorText) +1]; strcpy(flavorText, to_copy.flavorText); keywords = new char[strlen(to_copy.keywords) +1]; strcpy(keywords, to_copy.keywords); inPlay = to_copy.inPlay; tapped = to_copy.tapped; enchanted = to_copy.enchanted; cursed = to_copy.cursed; if (to_copy.type != ARTIFACT) artifact = to_copy.artifact; } // ====DECL===== int Card::equipArtifact(Artifact* to_equip){ artifact = to_equip; } Artifact * Card::unequipArtifact(Card * unequip_from){ Artifact * to_remove = artifact; artifact = NULL; return to_remove; // put card in hand or in graveyard } int Card::enchant( Card * to_enchant){ to_enchant->enchanted = true; cout << "enchanted" << endl; } int Card::disenchant( Card * to_disenchant){ to_disenchant->enchanted = false; cout << "Enchantment Removed" << endl; } // ========DECL===== Spell::Spell() { currPower = basePower; currToughness = baseToughness; classType = new char[strlen("Spell") + 1]; classType = "Spell"; } Spell::~Spell(){} // --------------- Spell::Spell(const Spell & to_copy){ currPower = to_copy.currPower; basePower = to_copy.basePower; currToughness = to_copy.currToughness; baseToughness = to_copy.baseToughness; } // ========= int Spell::attack( Spell *& blocker ){ blocker->currToughness -= currPower; currToughness -= blocker->currToughness; } //========== int Spell::counter (Spell *& to_counter){ cout << to_counter->name << " was countered by " << name << endl; } // ============ int Spell::heal (Spell *& to_heal, int amountOfHealth){ to_heal->currToughness += amountOfHealth; } // ------- Creature::Creature(){ summoningSick = true; } // =====DECL====== Land::Land(){ color = NON; classType = new char[strlen("Land") + 1]; classType = "Land"; } // ------ int Land::generateMana(int mana){ // ... // } card.h #ifndef CARD_H #define CARD_H #include <cctype> #include <iostream> #include "conception.h" class Artifact; class Spell; class Card : public Conception { public: Card(); Card(const Card &); ~Card(); protected: char* name; enum CardType { INSTANT, CREATURE, LAND, ENCHANTMENT, ARTIFACT, PLANESWALKER}; enum CardColor { WHITE, BLUE, BLACK, RED, GREEN, NON }; CardType type; CardColor color; int manaCost; char* abilities; char* flavorText; char* keywords; bool inPlay; bool tapped; bool cursed; bool enchanted; Artifact* artifact; virtual int enchant( Card * ); virtual int disenchant (Card * ); virtual int equipArtifact( Artifact* ); virtual Artifact* unequipArtifact(Card * ); }; // ------------ class Spell: public Card { public: Spell(); ~Spell(); Spell(const Spell &); protected: virtual int heal( Spell *&, int ); virtual int attack( Spell *& ); virtual int counter( Spell*& ); int currToughness; int baseToughness; int currPower; int basePower; }; class Land: public Card { public: Land(); ~Land(); protected: virtual int generateMana(int); }; class Forest: public Land { public: Forest(); ~Forest(); protected: int generateMana(); }; class Creature: public Spell { public: Creature(); ~Creature(); protected: bool summoningSick; }; class Sorcery: public Spell { public: Sorcery(); ~Sorcery(); protected: }; #endif conception.h -- this is an "uber class" from which everything derives class Conception{ public: Conception(); ~Conception(); protected: char* classType; }; conception.cpp Conception::Conception{ Conception(){ classType = new char[11]; char = "Conception"; } game.cpp -- this is an incomplete class as of this code #include <iostream> #include <cctype> #include "game.h" #include "player.h" Battlefield::Battlefield(){ card = 0; } Battlefield::~Battlefield(){ delete card; } Battlefield::Battlefield(const Battlefield & to_copy){ } // =========== /* class Game(){ public: Game(); ~Game(); protected: Player** player; // for multiple players Battlefield* root; // for battlefield getPlayerMove(); // ask player what to do addToBattlefield(); removeFromBattlefield(); sendAttack(); } */ #endif game.h #ifndef GAME_H #define GAME_H #include "list.h" class CardList(); class Battlefield : CardList{ public: Battlefield(); ~Battlefield(); protected: Card* card; // make an array }; class Game : Conception{ public: Game(); ~Game(); protected: Player** player; // for multiple players Battlefield* root; // for battlefield getPlayerMove(); // ask player what to do addToBattlefield(); removeFromBattlefield(); sendAttack(); Battlefield* field; }; list.cpp #include <iostream> #include <cctype> #include "list.h" // ========== LinkedList::LinkedList(){ root = new Node; classType = new char[strlen("LinkedList") + 1]; classType = "LinkedList"; }; LinkedList::~LinkedList(){ delete root; } LinkedList::LinkedList(const LinkedList & obj) { // code to copy } // --------- // ========= int LinkedList::delete_all(Node* root){ if (root = 0) return 0; delete_all(root->next); root = 0; } int LinkedList::add( Conception*& is){ if (root == 0){ root = new Node; root->next = 0; } else { Node * curr = root; root = new Node; root->next=curr; root->it = is; } } int LinkedList::remove(Node * root, Node * prev, Conception* is){ if (root = 0) return -1; if (root->it == is){ root->next = root->next; return 0; } remove(root->next, root, is); return 0; } Conception* LinkedList::find(Node*& root, const Conception* is, Conception* holder = NULL) { if (root==0) return NULL; if (root->it == is){ return root-> it; } holder = find(root->next, is); return holder; } Node* LinkedList::goForward(Node * root){ if (root==0) return root; if (root->next == 0) return root; else return root->next; } // ============ Node* LinkedList::goBackward(Node * root){ root = root->prev; } list.h #ifndef LIST_H #define LIST_H #include <iostream> #include "conception.h" class Node : public Conception { public: Node() : next(0), prev(0), it(0) { it = 0; classType = new char[strlen("Node") + 1]; classType = "Node"; }; ~Node(){ delete it; delete next; delete prev; } Node* next; Node* prev; Conception* it; // generic object }; // ---------------------- class LinkedList : public Conception { public: LinkedList(); ~LinkedList(); LinkedList(const LinkedList&); friend bool operator== (Conception& thing_1, Conception& thing_2 ); protected: virtual int delete_all(Node*); virtual int add( Conception*& ); // virtual Conception* find(Node *&, const Conception*, Conception* ); // virtual int remove( Node *, Node *, Conception* ); // removes question with keyword int display_all(node*& ); virtual Node* goForward(Node *); virtual Node* goBackward(Node *); Node* root; // write copy constrcutor }; // ============= class CircularLinkedList : public LinkedList { public: // CircularLinkedList(); // ~CircularLinkedList(); // CircularLinkedList(const CircularLinkedList &); }; class DoubleLinkedList : public LinkedList { public: // DoubleLinkedList(); // ~DoubleLinkedList(); // DoubleLinkedList(const DoubleLinkedList &); protected: }; // END OF LIST Hierarchy #endif player.cpp #include <iostream> #include "player.h" #include "list.h" using namespace std; Library::Library(){ root = 0; } Library::~Library(){ delete card; } // ====DECL========= Player::~Player(){ delete fname; delete lname; delete deck; } Wizard::~Wizard(){ delete mana; delete rootL; delete rootH; } // =====Player====== void Player::changeName(const char[] first, const char[] last){ char* backup1 = new char[strlen(fname) + 1]; strcpy(backup1, fname); char* backup2 = new char[strlen(lname) + 1]; strcpy(backup1, lname); if (first != NULL){ fname = new char[strlen(first) +1]; strcpy(fname, first); } if (last != NULL){ lname = new char[strlen(last) +1]; strcpy(lname, last); } return 0; } // ========== void Player::seeStats(Stats*& to_put){ to_put->wins = stats->wins; to_put->losses = stats->losses; to_put->winRatio = stats->winRatio; } // ---------- void Player::displayDeck(const LinkedList* deck){ } // ================ void CardList::findCard(Node* root, int id, NodeCard*& is){ if (root == NULL) return; if (root->it.id == id){ copyCard(root->it, is); return; } else findCard(root->next, id, is); } // -------- void CardList::deleteAll(Node* root){ if (root == NULL) return; deleteAll(root->next); root->next = NULL; } // --------- void CardList::removeCard(Node* root, int id){ if (root == NULL) return; if (root->id = id){ root->prev->next = root->next; // the prev link of root, looks back to next of prev node, and sets to where root next is pointing } return; } // --------- void CardList::addCard(Card* to_add){ if (!root){ root = new Node; root->next = NULL; root->prev = NULL; root->it = &to_add; return; } else { Node* original = root; root = new Node; root->next = original; root->prev = NULL; original->prev = root; } } // ----------- void CardList::displayAll(Node*& root){ if (root == NULL) return; cout << "Card Name: " << root->it.cardName; cout << " || Type: " << root->it.type << endl; cout << " --------------- " << endl; if (root->classType == "Spell"){ cout << "Base Power: " << root->it.basePower; cout << " || Current Power: " << root->it.currPower << endl; cout << "Base Toughness: " << root->it.baseToughness; cout << " || Current Toughness: " << root->it.currToughness << endl; } cout << "Card Type: " << root->it.currPower; cout << " || Card Color: " << root->it.color << endl; cout << "Mana Cost" << root->it.manaCost << endl; cout << "Keywords: " << root->it.keywords << endl; cout << "Flavor Text: " << root->it.flavorText << endl; cout << " ----- Class Type: " << root->it.classType << " || ID: " << root->it.id << " ----- " << endl; cout << " ******************************************" << endl; cout << endl; // ------- void CardList::copyCard(const Card& to_get, Card& put_to){ put_to.type = to_get.type; put_to.color = to_get.color; put_to.manaCost = to_get.manaCost; put_to.inPlay = to_get.inPlay; put_to.tapped = to_get.tapped; put_to.class = to_get.class; put_to.id = to_get.id; put_to.enchanted = to_get.enchanted; put_to.artifact = to_get.artifact; put_to.class = to_get.class; put.to.abilities = new char[strlen(to_get.abilities) +1]; strcpy(put_to.abilities, to_get.abilities); put.to.keywords = new char[strlen(to_get.keywords) +1]; strcpy(put_to.keywords, to_get.keywords); put.to.flavorText = new char[strlen(to_get.flavorText) +1]; strcpy(put_to.flavorText, to_get.flavorText); if (to_get.class = "Spell"){ put_to.baseToughness = to_get.baseToughness; put_to.basePower = to_get.basePower; put_to.currToughness = to_get.currToughness; put_to.currPower = to_get.currPower; } } // ---------- player.h #ifndef player.h #define player.h #include "list.h" // ============ class CardList() : public LinkedList(){ public: CardList(); ~CardList(); protected: virtual void findCard(Card&); virtual void addCard(Card* ); virtual void removeCard(Node* root, int id); virtual void deleteAll(); virtual void displayAll(); virtual void copyCard(const Conception*, Node*&); Node* root; } // --------- class Library() : public CardList(){ public: Library(); ~Library(); protected: Card* card; int numCards; findCard(Card&); // get Card and fill empty template } // ----------- class Deck() : public CardList(){ public: Deck(); ~Deck(); protected: enum deckColor { WHITE, BLUE, BLACK, RED, GREEN, MIXED }; char* deckName; } // =============== class Mana(int amount) : public Conception { public: Mana() : displayTotal(0), classType(0) { displayTotal = 0; classType = new char[strlen("Mana") + 1]; classType = "Mana"; }; protected: int accrued; void add(); void remove(); int displayTotal(); } inline Mana::add(){ accrued += 1; } inline Mana::remove(){ accrued -= 1; } inline Mana::displayTotal(){ return accrued; } // ================ class Stats() : public Conception { public: friend class Player; friend class Game; Stats() : wins(0), losses(0), winRatio(0) { wins = 0; losses = 0; if ( (wins + losses != 0) winRatio = wins / (wins + losses); else winRatio = 0; classType = new char[strlen("Stats") + 1]; classType = "Stats"; } protected: int wins; int losses; float winRatio; void int getStats(Stats*& ); } // ================== class Player() : public Conception{ public: Player() : wins(0), losses(0), winRatio(0) { fname = NULL; lname = NULL; stats = NULL; CardList = NULL; classType = new char[strlen("Player") + 1]; classType = "Player"; }; ~Player(); Player(const Player & obj); protected: // member variables char* fname; char* lname; Stats stats; // holds previous game statistics CardList* deck[]; // hold multiple decks that player might use - put ll in this private: // member functions void changeName(const char[], const char[]); void shuffleDeck(int); void seeStats(Stats*& ); void displayDeck(int); chooseDeck(); } // -------------------- class Wizard(Card) : public Player(){ public: Wizard() : { mana = NULL; rootL = NULL; rootH = NULL}; ~Wizard(); protected: playCard(const Card &); removeCard(Card &); attackWithCard(Card &); enchantWithCard(Card &); disenchantWithCard(Card &); healWithCard(Card &); equipWithCard(Card &); Mana* mana[]; Library* rootL; // Library Library* rootH; // Hand } #endif

    Read the article

< Previous Page | 3 4 5 6 7 8 9 10 11 12 13 14  | Next Page >