Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 198741
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 11, 20262026-05-11T16:57:49+00:00 2026-05-11T16:57:49+00:00

In Windows, what happens to an open HKEY variable if you don’t call RegCloseKey

  • 0

In Windows, what happens to an open HKEY variable if you don’t call RegCloseKey before the HKEY goes out of scope? I don’t see any errors or warnings, nor any memory leaks when the application closes. MSDN doesn’t offer much help, but makes it sound like it somehow uses up resources. Does anyone know what actually happens?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-11T16:57:49+00:00Added an answer on May 11, 2026 at 4:57 pm

    You orphan a handle, which are a limited (OK, it’s a pretty large limit) resource. However, once your app terminates the handle is eventually released by the OS, so the wasted resource is eventually returned to the pool.

    It’s bad programming practice, though, to allocate something that has limits and not release it when you’re done using it.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

This happens in IDLE and Windows 7 RC1 (if that helps). Here is the
Yea pretty much it. On windows xp sp3. This is what happens: jruby -S
I'm loading 3rd party DLLs and sometimes they open MessageBox windows that stops the
I just installed ruby 1.9.2 on windows machine and Backspace or any other arrow
I just found out how to have help open and the code editor open
I'm trying to open video player in windows 7 with PHP but can't seem
I am writing an application that uses OpenNETCF.IO.Serial (open source, see serial code here
On Windows 7 I open IE 8 and browse to localhost:80 and something is
I want to use a script to open a tmux session with 6 windows,
Mostly it happens if we open a team project from tfs 2008 or tfs

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.