Commit 376694a4 authored by Per Cederqvist's avatar Per Cederqvist
Browse files

(do_set_user_area): Indentation fixes.

parent a9ad0629
/*
* $Id: person.c,v 0.73 2002/11/25 16:27:14 ceder Exp $
* $Id: person.c,v 0.74 2003/01/06 12:23:16 ceder Exp $
* Copyright (C) 1991-1999, 2001-2002 Lysator Academic Computer Association.
*
* This file is part of the LysKOM server.
......@@ -292,7 +292,7 @@ do_set_user_area(Pers_no pers_no,
/* Check that the new user_area exists before deleting the old*/
if ( user_area != 0 )
if (user_area != 0)
{
GET_T_STAT(new_user_area, user_area, FAILURE);
......@@ -304,30 +304,33 @@ do_set_user_area(Pers_no pers_no,
return FAILURE;
}
if ( new_user_area->no_of_marks >= param.max_marks_text )
if (new_user_area->no_of_marks >= param.max_marks_text)
{
kom_log("%s(%d, %lu): New user_area's mark count (%d) > %d.\n",
"LIMIT: set_user_area",
pers_no, (unsigned long)user_area, new_user_area->no_of_marks,
param.max_marks_text);
kom_log("LIMIT: set_user_area(%d, %lu): "
"New user_area's mark count (%d) > %d.\n",
pers_no,
(unsigned long)user_area,
new_user_area->no_of_marks,
param.max_marks_text);
err_stat = user_area;
kom_errno = KOM_MARK_LIMIT;
return FAILURE;
}
}
if ( pers_p == NULL )
if (pers_p == NULL)
GET_P_STAT(pers_p, pers_no, FAILURE);
/* Unmark the previous user_area if it exists. */
if ( pers_p->user_area != 0
if (pers_p->user_area != 0
&& (old_user_area = cached_get_text_stat(pers_p->user_area)) != NULL)
{
if ( old_user_area->no_of_marks > 0 )
if (old_user_area->no_of_marks > 0)
{
--old_user_area->no_of_marks;
mark_text_as_changed( pers_p->user_area );
mark_text_as_changed(pers_p->user_area);
}
else
{
......@@ -340,14 +343,14 @@ do_set_user_area(Pers_no pers_no,
/* Mark the new user_area */
if ( user_area != 0 )
if (user_area != 0)
{
++new_user_area->no_of_marks;
mark_text_as_changed( user_area );
mark_text_as_changed(user_area);
}
pers_p->user_area = user_area;
mark_person_as_changed (pers_no);
mark_person_as_changed(pers_no);
return OK;
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment