Search Books

Debugging Windows Programs: Strategies, Tools, and Techniques for Visual C++ Programmers

Author Everett N. McKay, Mike Woodring
Publisher Addison-Wesley Professional
📄 Viewing lite version Full site ›
🌎 Shop on Amazon — choose country
41.46 44.95 USD
🛒 Buy New on Amazon 🇺🇸 🏷 Buy Used — $0.77

✓ Usually ships in 24 hours

Share:
Book Details
ISBN / ASIN020170238X
ISBN-139780201702385
AvailabilityUsually ships in 24 hours
Sales Rank1,580,545
MarketplaceUnited States 🇺🇸

Description

Debugging Windows Programs: Strategies, Tools, and Techniques for Visual C++ Programmers sounds like it might focus on using a debugger exclusively, but this book is actually a wide-ranging tour of how to write better, more robust Visual C++ code that can be debugged more easily. Mixing plenty of nuts-and-bolts tips with higher-level strategies for effective testing, Debugging Windows Programs offers plenty of valuable expertise for any working C++ programmer.

The focus is on providing practical tips for more successful debugging, but many of the suggestions are for tweaking the way in which you write C++ code. Early sections examine how to take full advantage of assert statements (whether in C, MFC, or custom functions), which can be used to write safer code; trace statements, which are used to log debug messages, are covered, too. (Chances are that you haven't seen all of the APIs; luckily, they're rounded up for you here.) There are also numerous tips about C++ style, like how to choose readable variable names, along with the debugging dos and don'ts of working with errors, exceptions, COM objects, and threads.

Chances are, even if you are an experienced Visual C++ programmer, you'll learn something useful about how to get more out of the C++ debugger from the last sections of this book. From the right compiler and linker switches (which can be mysterious) to how to customize watch variables by tweaking the configuration files in C++, you'll learn how to be more productive with this tool. The text concludes with another useful section, an FAQ-style listing of dozens of common debugging questions and answers.

Although it's highly practical, the book also recommends thinking about your code, applying strategies for each aspect of debugging features consistently and effectively. The bottom line is that you not only will find bugs in present code, but also you'll design code that's easier to test and debug in the future. In all, Debugging Windows Programs delivers a good mix of practical tips and strategies that'll help C++ programmers create more robust (and testable) code. --Richard Dragan

Topics covered:

    1. The debugging and testing process
    2. Tips for writing better Visual C++ code
    3. Assertions (C, MFC, and custom assert statements)
    4. Logging output with trace statements (including trace APIs)
    5. Exception handling and debugging
    6. First-chance and last-chance exceptions
    7. Tips for better debugging in C++
    8. Naming conventions
    9. Postmortem
    10. Just-in-time (JIT) and remote debugging
    11. Using map and .pdb files
    12. Compiler and linking options
    13. Debug windows
    14. Customizing the C++ debugging environment
    15. Basic and advanced debugging techniques
    16. Catching memory leaks with the debug heap
    17. Debugging multithreaded programs (including avoiding race conditions and deadlock)
    18. A primer for COM debugging
    19. Frequently asked questions and answers about debugging