BACKPORT: vsprintf: refactor %pK code out of pointer()

Currently code to handle %pK is all within the switch statement in
pointer(). This is the wrong level of abstraction. Each of the other switch
clauses call a helper function, pK should do the same.

Refactor code out of pointer() to new function restricted_pointer().

Signed-off-by: Tobin C. Harding <me@tobin.cc>
(cherry picked from commit 57e734423adda83f3b05505875343284efe3b39c)
Signed-off-by: Sandeep Patil <sspatil@android.com>

Bug: 78533979
Test: Build and boot cuttlefish
Change-Id: Ib08350851ab0e99a3569c2c2e12aa421fb6bc622
1 file changed