how to get gdi and user objects info in windbg

Hi,
i want to get info about the gdi and user object owned by a process using windbg debugger.
i know how to get handle list and stacktrace, and i want somehting similar for gdi and user objects.
i also know that the process has a table with these handles somewhere, just dont now how to get/use it.

thanks,
A.
LVL 11
AgariciAsked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

jkrCommented:
You can use WinDbg to obtain the "Process Environment Block (PEB)" (see http://msdn.microsoft.com/msdnmag/issues/03/01/GDILeaks/default.aspx?loc=&fig=true#fig2) and it's GdiSharedHandleTable field, see also http://msdn.microsoft.com/msdnmag/issues/03/01/GDILeaks/#S2
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
primeMover2004Commented:
Get Windows DDK.
Fire up WinDBG
load your executable
break

!load gdikdx
!help
=======================================================================
GDIEXTS server debugger extentions:
--------------------------------------------------------------------
- general extensions -
dumphmgr -- handle manager objects
dumpobj [-p pid] [type] -- all objects of specific type
dh [object handle] -- HMGR entry of handle
dht [object handle] -- handle type/uniqueness/index
ddc [DC handle] -- DC obj (ddc -? for more info)
dpdev [PDEV ptr] -- PDEV object (dpdev -? for more info)
dldev [LDEV ptr]  LDEV
dco [CLIPOBJ ptr]  CLIPOBJ
dpo [PATHOBJ ptr]  PATHOBJ
dppal [EPALOBJ ptr]  EPALOBJ
dpbrush [BRUSH ptr]  BRUSH
dpsurf [SURFACE ptr]  SURFACE
dpso [SURFOBJ ptr] -- SURFACE struct from SURFOBJ
dblt [BLTRECORD ptr]  BLTRECORD
dr [REGION ptr]  REGION
cr [REGION ptr] -- check REGION
dddsurface [EDD_SURFACE ptr] -- EDD_SURFACE
dddlocal [EDD_DIRECTDRAW_LOCAL ptr] -- EDD_DIRECTDRAW_LOCAL
ddglobal [EDD_DIRECTDRAW_GLOBAL ptr] -- EDD_DIRECTDRAW_GLOBAL
rgnlog nnn -- last nnn rgnlog entries
stats -- accumulated statistics
hdc HDC [-?gltf]
dcl DCLEVEL*
dca DC_ATTR*
ca COLORADJUSTMENT*
mx MATRIX*
la LINEATTRS*
ef EFLOAT* [count]
mx MATRIX*
- font extensions -
tstats
gs FD_GLYPHSET*
gdata GLYPHDATA*
elf EXTLOGFONTW*
tm TEXTMETRICW*
tmwi TMW_INTERNAL*
helf HFONT
ifi IFIMETRICS*
fo RFONT* [-?axedtrfmoculhw]
pfe PFE*
pff PFF*
pft PFT*
stro STROBJ* [-?pheo]
gb GLYPHBITS* [-?gh]
gdf GLYPHDEF*
gp GLYPHPOS*
cache CACHE*
fh FONTHASH*
hb HASHBUCKET*
pubft -- dumps all PUBLIC fonts
devft -- dumps all DEVICE fonts
dispcache -- dumps glyph cache for display PDEV
client side extensions
clihelp
0
AgariciAuthor Commented:
thank you both for the reply.
A.
0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Microsoft Development

From novice to tech pro — start learning today.