Rookie question, but I am confused here :)
So, lets say we have the following function: $$f(x) = \frac{x-1}{x^2 -1}$$ It also equals to:
$$g(x) = \frac{1}{ x + 1}$$
$g(x)$ is defined at $x=1$ but $f(x)$ isn't. In a similar way, we could make any function undefined at any point $p$, at a $x$-coordinate we desire simply by multiplying the function by $\frac{p - x}{ p -x}$.
What am I missing here?
It comes down to understanding how functions are defined. A function $f$ is a subset of a Cartesian product of two sets $A$ and $B$, satisfying certain properties. That is, $f$ is a set of ordered pairs in the form $(a, b)$, where $a \in A$ and $b \in B$. It must additionally satisfy the following two properties:
The first condition states that every element $a \in A$ must occur in at least one ordered pair $(a, b) \in f$, and the second condition states that every element $a \in A$ must occur in at most one ordered pair $(a, b) \in f$. So, in total, every element $a \in A$ must occur in exactly one ordered pair $(a, b) \in f$. This means, for every element of $a \in A$, there is a unique associated $b \in B$, and we denote this $b$ by $f(a)$.
We call the set $A$ the domain of $f$, and $B$ the codomain of $f$. As coffeemath points out, it's important to specify the domain and codomain. Technically speaking, the rule $x \mapsto \frac{x^2 - 1}{x - 1}$ does not define a function from $\Bbb{R}$ to $\Bbb{R}$, as it fails to associate some $b \in \Bbb{R}$ to $a = 1$, in violation of the first property.
Instead, this rule can be naturally turned into a function on $\Bbb{R} \setminus \{1\}$. This is the largest subset of $\Bbb{R}$ on which this rule defines a function. This is what is often called the "natural domain". If you consider a rule like $x \mapsto \frac{x^2 - 1}{x - 1}$ to be a function, the domain is typically taken to be the natural domain, which is (again) $\Bbb{R} \setminus \{1\}$.
Compare this to the rule $x \mapsto x + 1$. This is defined for every $x \in \Bbb{R}$, so its natural domain is $\Bbb{R}$. Without specifying domains, and simply defining \begin{align*} f(x) &= \frac{x^2 - 1}{x - 1} \\ g(x) &= x + 1, \end{align*} then, by convention, you are defining $f$ and $g$ as functions on their respective natural domains (to the codomain $\Bbb{R}$). This means $f$ and $g$ are not the same! As sets, we have $(1, 2) \in g$ (as $g(1) = 2$), but $(1, 2) \notin f$.
In fact, simply knowing that $1$ lies in the domain of $g$, but not in $f$, is enough to know that these functions are not equal. From the first condition, we know that $(1, b) \in g$ for some $b$, but since $f$ is a subset of its domain multiplied to its codomain, and $1$ does not lie in its domain, then there is no element of the form $(1, b)$ in $f$. Thus, necessarily, $f \neq g$.