Convert number to X base
Your code does not handle negative numbers.  As it is, it will print nothing.  The code should be changed to either handle the negatives properly, or take number as an unsigned where it is not an issue.

Your use of base as the length of the array to store the converted number in is incorrect.  A 32-bit integer will potentially need 32 characters to display the entire number, assuming no zero byte terminator (see below).  buffer should be declared as a fixed size, large enough to hold the longest possible string.  You could then eliminate the i &lt; base check from your while loop.

The initial check of if (!number) can be eliminated by changing your while loop into a do/while look.

If you're looking for brevity in code lines, the body of the loop can be reduced to two statements, although it is more readable with three or four.

The assignment of a 0 byte to the end of buffer is unnecessary in this context since you never pass buffer to a function that requires it.