Re: Gnome-session IO to profile files?



В Пнд, 14/07/2008 в 20:51 +0100, Artur Martins пишет:
> Hi there,
> 
> This is a re-write of an email that i sent to this list about a week
> ago, from which i got no answer.
> 
> I'm developing a transactional layer for file-system access (for my
> MSc Thesis), and i would like to test\use it (PoC) by patching the
> gnome-session source-code, so that in the end i can guarantee that
> either all my user-session files get saved, or none do (atomicity
> property achieved thru journaling).
> 
> For this i need to find the fopen\fread\fwrite calls that gnome makes
> whenever it wants to save\load my profile files.
> I have watched the save.c and gnome-session-save.c files in the latest
> gnome-session package, but all the file writes seem to be done with
> snprintf... And no, i could not find any mmaps..
> 
> Could anyone please tell me where are the file IOs for gnome-session?
> I need to wrap these around a transactional START and COMMIT calls.
> 
> 
> I have 1 week to get a PoC for my prototype, so please please help me
> out finding this (you sure know what i need).
> 

If you didn't figure that already, the session itself doesn't save the
data. Instead it signals clients with dbus that session is saved and
each client using session module save it's state. The code to save the
state is located in egg/eggsmclient-xsmp.c and it uses
g_file_set_contents to save actual desktop file in .gnome2/session. The
function is 

static void save_state (EggSMClientXSMP *xsmp)




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]