Fixed a few problems

Change-Id: I1f7017bc8764e042efba9d35341fb9400d78fa21