/* Returns: the element, or NULL if the position is off the end of the #GSList  */
GSList* g_slist_nth(GSList *list, guint n)
/* Returns: the element, or NULL if the position is off the end of the #GSList  */
GSList* g_slist_nth(GSList *list, guint n)
{
  while (n-- > 0 && list)
    list = list->next;
  return list;
}