• R/O
  • HTTP
  • SSH
  • HTTPS

Commit

Tags
Aucun tag

Frequently used words (click to add to your profile)

javac++androidlinuxc#windowsobjective-ccocoa誰得qtpythonphprubygameguibathyscaphec計画中(planning stage)翻訳omegatframeworktwitterdomtestvb.netdirectxゲームエンジンbtronarduinopreviewer

*NIXコンソール用Google ToDo(Tasks) クライアント


Commit MetaInfo

Révision74b38441d3649ea4da5e7f5694e6d96fd3577341 (tree)
l'heure2021-03-08 20:55:30
AuteurKoine Yuusuke(koinec) <koinec@user...>
CommiterKoine Yuusuke(koinec)

Message de Log

Check exist default TaskList before Add/Move/Delete/Complete/Undo operation.

Change Summary

Modification

--- a/src/todocmd_scenery.c
+++ b/src/todocmd_scenery.c
@@ -49,6 +49,12 @@ int
4949
5050 if( NULL == pstr_id ) { return 0x03; }
5151
52+ if( NO_TODODATA == LibToDo_GetTopDataID() ) {
53+ fputs(" Error!: Do not exist default TaskList in the cache.\n\n", stderr);
54+ fputs(" Please load default TaskList from Google Cloud by executing the \"todocmd list -r\" command.\n\n", stderr );
55+ return 0x03;
56+ }
57+
5258 i_confirm = Common_GetToDoID_fromIndicateStr( &i_taskid, pstr_id );
5359 if( 0x00 > i_confirm ) {
5460 puts(" Error!: Invalid TaskID.");
@@ -110,6 +116,12 @@ int
110116
111117 if( NULL == pstr_id ) { return 0x03; }
112118
119+ if( NO_TODODATA == LibToDo_GetTopDataID() ) {
120+ fputs(" Error!: Do not exist default TaskList in the cache.\n\n", stderr);
121+ fputs(" Please load default TaskList from Google Cloud by executing the \"todocmd list -r\" command.\n\n", stderr );
122+ return 0x03;
123+ }
124+
113125 i_confirm = Common_GetToDoID_fromIndicateStr( &i_taskid, pstr_id );
114126 if( 0x00 > i_confirm ) {
115127 puts(" Error!: Invalid TaskID.");
@@ -208,7 +220,13 @@ int
208220 LibToDo_Data *p_tprev;
209221 LibToDo_Data *p_tparent;
210222
211- if( NULL == pstr_title ) { return 0x03; }
223+ if( NULL == pstr_title ) { return 0x02; }
224+
225+ if( NO_TODODATA == LibToDo_GetTopDataID() ) {
226+ fputs(" Error!: Do not exist default TaskList in the cache.\n\n", stderr);
227+ fputs(" Please load default TaskList from Google Cloud by executing the \"todocmd list -r\" command.\n\n", stderr );
228+ return 0x03;
229+ }
212230
213231 // Alloc ToDoData Buffer ---
214232 p_tdata = (LibToDo_Data *)malloc( 3 * sizeof( LibToDo_Data ) );
@@ -354,6 +372,12 @@ int
354372 if( ! strncmp( pstr_taskid, pstr_previd, 64) )
355373 { return 0x03; }
356374
375+ if( NO_TODODATA == LibToDo_GetTopDataID() ) {
376+ fputs(" Error!: Do not exist default TaskList in the cache.\n\n", stderr);
377+ fputs(" Please load default TaskList from Google Cloud by executing the \"todocmd list -r\" command.\n\n", stderr );
378+ return 0x03;
379+ }
380+
357381 // Alloc ToDoData Buffer ---
358382 p_tdata = (LibToDo_Data *)malloc( 5 * sizeof( LibToDo_Data ) );
359383 if( NULL == p_tdata ) { return 0x04; }
@@ -484,6 +508,12 @@ int
484508
485509 if( NULL == pstr_id ) { return 0x03; }
486510
511+ if( NO_TODODATA == LibToDo_GetTopDataID() ) {
512+ fputs(" Error!: Do not exist default TaskList in the cache.\n\n", stderr);
513+ fputs(" Please load default TaskList from Google Cloud by executing the \"todocmd list -r\" command.\n\n", stderr );
514+ return 0x03;
515+ }
516+
487517 i_confirm = Common_GetToDoID_fromIndicateStr( &i_taskid, pstr_id );
488518 if( 0x00 > i_confirm ) {
489519 puts(" Error!: Invalid TaskID.");